tests: Make tests pass on pyboard.

pull/479/head
Damien George 2014-04-13 17:46:30 +01:00
rodzic 9dcc60d0b1
commit 4417478d0f
4 zmienionych plików z 7 dodań i 3 usunięć

Wyświetl plik

@ -31,3 +31,5 @@ a.foo(1, 2, *[100])
# Iterator
a.foo(*range(3))
print('flush') # so that it works on pyboard...

Wyświetl plik

@ -18,3 +18,5 @@ try:
fun2(1, 2, 3, 4)
except TypeError:
print("TypeError")
print('flush') # so that it works on pyboard...

Wyświetl plik

@ -38,8 +38,8 @@ except ValueError:
# These recursive try-finally tests are attempt to get some interpretation
# of last phrase in http://docs.python.org/3.4/library/dis.html#opcode-WITH_CLEANUP
# "If the stack represents an exception, and the function call returns a true
# value, this information is “zapped” and replaced with a single WHY_SILENCED
# "If the stack represents an exception, and the function call returns a 'true'
# value, this information is "zapped" and replaced with a single WHY_SILENCED
# to prevent END_FINALLY from re-raising the exception. (But non-local gotos
# will still be resumed.)"
print("===")

Wyświetl plik

@ -49,7 +49,7 @@ for test_file in tests:
if test_on_pyboard:
pyb.enter_raw_repl()
try:
if test_file == 'basics/math-fun.py':
if test_file == 'basics/memoryerror.py':
# this test crashes the pyboard
output_mupy = b'CRASH'
else: