Skip to content

Commit 06643a0

Browse files
stinosdpgeorge
authored andcommitted
tests/extmod: Skip uselect test when CPython doesn't have poll().
CPython does not have an implementation of select.poll() on some operating systems (Windows, OSX depending on version) so skip the test in those cases instead of failing it.
1 parent e328a5d commit 06643a0

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

tests/extmod/uselect_poll_basic.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,8 @@
33
except ImportError:
44
try:
55
import socket, select, errno
6-
except ImportError:
6+
select.poll # Raises AttributeError for CPython implementations without poll()
7+
except (ImportError, AttributeError):
78
print("SKIP")
89
raise SystemExit
910

0 commit comments

Comments
 (0)