← index #5907PR #18543
Off-topic · high · value 4.859
QUERY · ISSUE

esp32: viper tests fail after a while

openby tveopened 2020-04-11updated 2020-04-13
port-esp32

If I execute a micropython/viper test on an esp32 in a loop it starts failing after a while (I started with a HW reset before this):

> while true; ./run-tests --device /dev/ttyUSB0 --target esp32 micropython/
viper_ptr32_load.py; end
pass  micropython/viper_ptr32_load.py
1 tests performed (4 individual testcases)
1 tests passed
[...]
pass  micropython/viper_ptr32_load.py
1 tests performed (4 individual testcases)
1 tests passed
FAIL  micropython/viper_ptr32_load.py
1 tests performed (4 individual testcases)
0 tests passed
1 tests failed: viper_ptr32_load
skip  micropython/viper_ptr32_load.py
0 tests performed (0 individual testcases)
0 tests passed
1 tests skipped: viper_ptr32_load

It takes less than a minute to get there. I noticed because running the full test suite shows this, e.g.:

> ./run-tests --device /dev/ttyUSB0 --target esp32 -d micropython
[...]
pass  micropython/viper_misc_intbig.py
pass  micropython/viper_ptr16_load.py
pass  micropython/viper_ptr16_store.py
pass  micropython/viper_ptr32_load.py
pass  micropython/viper_ptr32_store.py
FAIL  micropython/viper_ptr8_load.py
FAIL  micropython/viper_ptr8_store.py
FAIL  micropython/viper_subscr.py
FAIL  micropython/viper_try.py
FAIL  micropython/viper_types.py
FAIL  micropython/viper_with.py
65 tests performed (411 individual testcases)
59 tests passed
4 tests skipped: heap_locked heapalloc_bytesio2 meminfo memstats
6 tests failed: viper_ptr8_load viper_ptr8_store viper_subscr viper_try viper_types viper_with

The tests that fail at the end are because they're at the end, not because they fail per-se.

CANDIDATE · PULL REQUEST

tests: Fix ESP8266 test failures.

mergedby agattiopened 2025-12-10updated 2025-12-17
tests

Summary

This PR contains some small changes to the test suite to let test runs complete cleanly on ESP8266.

  • extmod/machine_uart_tx.py would fail with an ImportError since there was no ESP8266 wiring module. An appropriate module is now present and the test was updated with ESP8266-specific timing data
  • extmod/vfs_blockdev_invalid.py would run out of memory when executing the second half of the test. The test was rewritten to delay any success output until validation is performed, returning the appropriate marker in case of a low memory condition
  • stress/list_sort.py would take too long to complete, triggering the OS watchdog. The test is now skipped as part of the ESP8266 test run.

Testing

Besides the regular CI tests, the test suite executed without special options now completes with no errors on an ESP8266EX board.

Keyboard

j / / n
next pair
k / / p
previous pair
1 / / h
show query pane
2 / / l
show candidate pane
c
copy suggested comment
r
toggle reasoning
g i
go to index
?
show this help
esc
close overlays

press ? or esc to close

copied