Commit ce4271a3 authored by Berker Peksag's avatar Berker Peksag

Issue #26536: Skip test_sio_loopback_fast_path under Windows 7

parent f95de0e8
......@@ -1223,10 +1223,16 @@ class GeneralModuleTests(unittest.TestCase):
def test_sio_loopback_fast_path(self):
s = socket.socket()
self.addCleanup(s.close)
s.ioctl(socket.SIO_LOOPBACK_FAST_PATH, True)
try:
s.ioctl(socket.SIO_LOOPBACK_FAST_PATH, True)
except OSError as exc:
WSAEOPNOTSUPP = 10045
if exc.winerror == WSAEOPNOTSUPP:
self.skipTest("SIO_LOOPBACK_FAST_PATH is defined but "
"doesn't implemented in this Windows version")
raise
self.assertRaises(TypeError, s.ioctl, socket.SIO_LOOPBACK_FAST_PATH, None)
def testGetaddrinfo(self):
try:
socket.getaddrinfo('localhost', 80)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment