forked from M-Labs/nac3
[standalone] Add tests for string equality
This commit is contained in:
parent
4d80ba38b7
commit
b8dab6cf7c
|
@ -0,0 +1,30 @@
|
|||
@extern
|
||||
def output_bool(x: bool):
|
||||
...
|
||||
|
||||
|
||||
def str_eq():
|
||||
output_bool("" == "")
|
||||
output_bool("a" == "")
|
||||
output_bool("a" == "b")
|
||||
output_bool("b" == "a")
|
||||
output_bool("a" == "a")
|
||||
output_bool("test string" == "test string")
|
||||
output_bool("test string1" == "test string2")
|
||||
|
||||
|
||||
def str_ne():
|
||||
output_bool("" != "")
|
||||
output_bool("a" != "")
|
||||
output_bool("a" != "b")
|
||||
output_bool("b" != "a")
|
||||
output_bool("a" != "a")
|
||||
output_bool("test string" != "test string")
|
||||
output_bool("test string1" != "test string2")
|
||||
|
||||
|
||||
def run() -> int32:
|
||||
str_eq()
|
||||
str_ne()
|
||||
|
||||
return 0
|
Loading…
Reference in New Issue