diff options
| author | Damien George <damien@micropython.org> | 2025-10-03 22:50:20 +1000 |
|---|---|---|
| committer | Damien George <damien@micropython.org> | 2025-10-20 11:18:59 +1100 |
| commit | 60edfeeead49cba018c9695a0fa10f812b1e04d9 (patch) | |
| tree | 705a9114eaf9a8dafe9c33c50d9013b200e09f7d /tests/net_inet/test_sslcontext_client.py | |
| parent | 93f13dd88291b54d4fcd8acafe5c1f8ac6d823df (diff) | |
tests/run-tests.py: Raise OSError on invalid file open for injected FS.
This makes sure that `open()` raises `OSError(ENOENT)` if the test script
attempts to open a file that does not exist.
For example, the test `tests/ports/esp32/check_err_str.py` attempts to do
this and this test currently fails when run with `--via-mpy` because the
injected filesystem lets a file by any name be opened.
The fix here tries to be as minimal as possible, so includes a size
optimisation for `stat()` to use a fixed 10-tuple. It also fixes the
`OSError` argument, which should be positive.
Signed-off-by: Damien George <damien@micropython.org>
Diffstat (limited to 'tests/net_inet/test_sslcontext_client.py')
0 files changed, 0 insertions, 0 deletions
