tests/cmdline: Add test for REPL auto-indent.

Signed-off-by: Damien George <damien@micropython.org>
pull/8391/head
Damien George 2022-04-13 17:39:05 +10:00
rodzic 6d401be4dd
commit 6bec5c4da5
2 zmienionych plików z 38 dodań i 0 usunięć

Wyświetl plik

@ -0,0 +1,16 @@
# tests for autoindent
if 1:
print(1)
if 0:
print(2)
else:
print(3)
if 0:
print(4)
else:
print(5)

Wyświetl plik

@ -0,0 +1,22 @@
MicroPython \.\+ version
Use \.\+
>>> # tests for autoindent
>>> if 1:
... print(1)
...
...
...
1
>>> if 0:
...  print(2)
... else:
... print(3)
...
3
>>> if 0:
... print(4)
... else:
... print(5)
...
5
>>>