Skip to content

Commit 1a71d30

Browse files
committed
tests/micropython: Make uio-using tests skippable.
1 parent e8d4527 commit 1a71d30

2 files changed

Lines changed: 13 additions & 2 deletions

File tree

tests/micropython/heapalloc_bytesio.py

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,10 @@
1-
import uio
1+
try:
2+
import uio
3+
except ImportError:
4+
import sys
5+
print("SKIP")
6+
sys.exit()
7+
28
import micropython
39

410
data = b"1234" * 16

tests/micropython/heapalloc_traceback.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,12 @@
22

33
import micropython
44
import sys
5-
import uio
5+
try:
6+
import uio
7+
except ImportError:
8+
import sys
9+
print("SKIP")
10+
sys.exit()
611

712
# preallocate exception instance with some room for a traceback
813
global_exc = StopIteration()

0 commit comments

Comments
 (0)