Skip to content

Commit b6b0451

Browse files
serhiy-storchakamiss-islington
authored andcommitted
Skip a test for Bluetooth HCI socket (added in pythonGH-132023) if it fails (pythonGH-132072)
(cherry picked from commit ef70f02) Co-authored-by: Serhiy Storchaka <[email protected]>
1 parent a5ed920 commit b6b0451

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

Lib/test/test_socket.py

+6-1
Original file line numberDiff line numberDiff line change
@@ -2699,7 +2699,12 @@ def testBindHciSocket(self):
26992699
self.assertEqual(addr, socket.BDADDR_ANY)
27002700
else:
27012701
dev = 0
2702-
s.bind((dev,))
2702+
try:
2703+
s.bind((dev,))
2704+
except OSError as err:
2705+
if err.errno in (errno.EINVAL, errno.ENODEV):
2706+
self.skipTest(str(err))
2707+
raise
27032708
addr = s.getsockname()
27042709
self.assertEqual(addr, dev)
27052710

0 commit comments

Comments
 (0)