Commit bd0fa0ef authored by Jason Madden's avatar Jason Madden

actually fix test__socket_ex on win/py3

parent 4d8a23c6
......@@ -12,9 +12,16 @@ class TestClosedSocket(greentest.TestCase):
sock.close()
try:
sock.send(b'a', timeout=1)
raise AssertionError("Should not get here")
except (socket.error, OSError) as ex:
if ex.args[0] != errno.EBADF:
raise
if sys.platform.startswith('win'):
# Windows/Py3 raises "OSError: [WinError 10038] "
# which is not standard and not what it does
# on Py2.
pass
else:
raise
class TestRef(greentest.TestCase):
......
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