summaryrefslogtreecommitdiff
path: root/tests/test_async.py
diff options
context:
space:
mode:
authorDaniele Varrazzo <daniele.varrazzo@gmail.com>2010-11-25 03:02:58 +0000
committerDaniele Varrazzo <daniele.varrazzo@gmail.com>2010-11-25 03:13:49 +0000
commit9f781415326db3e09696b0601250b999bd4f6a0e (patch)
tree7fad0d3d17d91c6e614c920491aa460d738b0944 /tests/test_async.py
parent5a025825cc4843e7f57f97db50c471a881380f9f (diff)
downloadpsycopg2-9f781415326db3e09696b0601250b999bd4f6a0e.tar.gz
Don't consider the kernel not blocking us on write as an error.
Diffstat (limited to 'tests/test_async.py')
-rwxr-xr-xtests/test_async.py7
1 files changed, 6 insertions, 1 deletions
diff --git a/tests/test_async.py b/tests/test_async.py
index c839604..05b2344 100755
--- a/tests/test_async.py
+++ b/tests/test_async.py
@@ -328,7 +328,12 @@ class AsyncTests(unittest.TestCase):
if stub.polls.count(psycopg2.extensions.POLL_WRITE) > 1:
return
- self.fail("sending a large query didn't trigger block on write.")
+ # This is more a testing glitch than an error: it happens
+ # on high load on linux: probably because the kernel has more
+ # buffers ready. A warning may be useful during development,
+ # but an error is bad during regression testing.
+ import warnings
+ warnings.warn("sending a large query didn't trigger block on write.")
def test_sync_poll(self):
cur = self.sync_conn.cursor()