Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
TASTE
uPython-mirror
Commits
a7ffa972
Commit
a7ffa972
authored
Sep 07, 2015
by
Damien George
Browse files
tests: Add tests for non-compliant behaviour of lexer.
parent
558a016e
Changes
2
Hide whitespace changes
Inline
Side-by-side
tests/misc/non_compliant_lexer.py
0 → 100644
View file @
a7ffa972
# lexer tests for things that are not implemented, or have non-compliant behaviour
# uPy requires spaces between literal numbers and keywords, CPy doesn't
try
:
eval
(
'1and 0'
)
except
SyntaxError
:
print
(
'SyntaxError'
)
try
:
eval
(
'1or 0'
)
except
SyntaxError
:
print
(
'SyntaxError'
)
try
:
eval
(
'1if 1else 0'
)
except
SyntaxError
:
print
(
'SyntaxError'
)
try
:
eval
(
'1if 0else 0'
)
except
SyntaxError
:
print
(
'SyntaxError'
)
tests/misc/non_compliant_lexer.py.exp
0 → 100644
View file @
a7ffa972
SyntaxError
SyntaxError
SyntaxError
SyntaxError
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment