Commit 15018291 authored by Alex March's avatar Alex March Committed by Damien George

tests: Add escaped quotes tests for REPL.

Test possible combinations of single and double quotes with escaped
quotes and parenthesis with and without function calls in REPL.

Covers: #1419
parent bfb272b9
# check REPL allows to continue input # check REPL allows to continue input
1 \ 1 \
+ 2 + 2
'"'
"'"
'\''
"\""
'\'('
"\"("
print("\"(")
print('\'(')
print("\'(")
print('\"(')
'abc' 'abc'
"abc" "abc"
'''abc '''abc
......
...@@ -3,6 +3,26 @@ Micro Python \.\+ version ...@@ -3,6 +3,26 @@ Micro Python \.\+ version
>>> 1 \\\\ >>> 1 \\\\
... + 2 ... + 2
3 3
>>> '"'
'"'
>>> "'"
"'"
>>> '\\\\''
"'"
>>> "\\\\""
'"'
>>> '\\\\'('
"'("
>>> "\\\\"("
'"('
>>> print("\\\\"(")
"(
>>> print('\\\\'(')
'(
>>> print("\\\\'(")
'(
>>> print('\\\\"(')
"(
>>> 'abc' >>> 'abc'
'abc' 'abc'
>>> "abc" >>> "abc"
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment