tests: Add some more tests to improve coverage of py/parse.c.

This commit is contained in:
Damien George
2017-12-19 16:13:00 +11:00
parent ae1be76d40
commit 35a759dc1d
6 changed files with 25 additions and 3 deletions

View File

@@ -29,6 +29,10 @@ test_syntax(" a\n")
# malformed integer literal (parser error)
test_syntax("123z")
# input doesn't match the grammar (parser error)
test_syntax('1 or 2 or')
test_syntax('{1:')
# can't assign to literals
test_syntax("1 = 2")
test_syntax("'' = 1")