mirror of
https://github.com/psycopg/psycopg2.git
synced 2024-11-29 12:23:42 +03:00
Added select.select timeout on AsyncTests.wait
On Windows, the select.select() hangs/waits forever on the test_async_connection_error_message() test. Adding a 10 second timeout allows the tests to continue.
This commit is contained in:
parent
97290955f6
commit
c5f2e29dde
|
@ -75,9 +75,9 @@ class AsyncTests(ConnectingTestCase):
|
|||
if state == psycopg2.extensions.POLL_OK:
|
||||
break
|
||||
elif state == psycopg2.extensions.POLL_READ:
|
||||
select.select([pollable], [], [])
|
||||
select.select([pollable], [], [], 10)
|
||||
elif state == psycopg2.extensions.POLL_WRITE:
|
||||
select.select([], [pollable], [])
|
||||
select.select([], [pollable], [], 10)
|
||||
else:
|
||||
raise Exception("Unexpected result from poll: %r", state)
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user