Skip to content

Commit eed2f36

Browse files
committed
tests/run-tests: Allow to skip complex tests if it's not compiled in.
1 parent 082b121 commit eed2f36

1 file changed

Lines changed: 7 additions & 0 deletions

File tree

tests/run-tests

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -182,13 +182,20 @@ def run_tests(pyb, tests, args):
182182
skip_tests.add('cmdline/cmd_showbc.py')
183183

184184
upy_byteorder = run_micropython(pyb, args, 'feature_check/byteorder.py')
185+
has_complex = run_micropython(pyb, args, 'feature_check/complex.py') == b'complex\n'
185186
cpy_byteorder = subprocess.check_output([CPYTHON3, 'feature_check/byteorder.py'])
186187
skip_endian = (upy_byteorder != cpy_byteorder)
187188

188189
# Some tests shouldn't be run under Travis CI
189190
if os.getenv('TRAVIS') == 'true':
190191
skip_tests.add('basics/memoryerror.py')
191192

193+
if not has_complex:
194+
skip_tests.add('float/complex1.py')
195+
skip_tests.add('float/int_big_float.py')
196+
skip_tests.add('float/true_value.py')
197+
skip_tests.add('float/types.py')
198+
192199
# Some tests shouldn't be run on pyboard
193200
if pyb is not None:
194201
skip_tests.add('basics/exception_chain.py') # warning is not printed

0 commit comments

Comments
 (0)