Added more tests
This commit is contained in:
parent
a75aad52f6
commit
49214c9a6e
8 changed files with 74 additions and 41 deletions
17
tests/programs/operator-number.q
Normal file
17
tests/programs/operator-number.q
Normal file
|
@ -0,0 +1,17 @@
|
|||
main() {
|
||||
f(10)
|
||||
}
|
||||
|
||||
f(x int) {
|
||||
y := x
|
||||
x = x - 2
|
||||
assert x < y
|
||||
x = x + 2
|
||||
assert x == y
|
||||
x = x * 2
|
||||
assert x > y
|
||||
x = x / 2
|
||||
assert x == y
|
||||
x = x % 2
|
||||
assert x < 2
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue