summaryrefslogtreecommitdiff
path: root/tests/test_async.py
diff options
context:
space:
mode:
authorFederico Di Gregorio <fog@initd.org>2010-04-14 10:01:37 +0200
committerFederico Di Gregorio <fog@initd.org>2010-04-14 10:01:37 +0200
commit249b3ef88fcb57cddf9992175d60c782ee663b25 (patch)
tree29c1a51601888f1ce3438a8a215a9aca500c5038 /tests/test_async.py
parent5f4ef5da13298ebd1bf9d958f1590b4d4adde3de (diff)
downloadpsycopg2-249b3ef88fcb57cddf9992175d60c782ee663b25.tar.gz
Merged tests from piro and jan async fixes branches
Diffstat (limited to 'tests/test_async.py')
-rwxr-xr-xtests/test_async.py5
1 files changed, 2 insertions, 3 deletions
diff --git a/tests/test_async.py b/tests/test_async.py
index de853e7..5333b0d 100755
--- a/tests/test_async.py
+++ b/tests/test_async.py
@@ -301,7 +301,6 @@ class AsyncTests(unittest.TestCase):
curs = self.conn.cursor()
for mb in 1, 5, 10, 20, 50:
size = mb * 1024 * 1024
- print "\nplease wait: sending", mb, "MB query to the server",
stub = PollableStub(curs)
curs.execute("select %s;", ('x' * size,))
self.wait(stub)
@@ -324,7 +323,7 @@ class AsyncTests(unittest.TestCase):
# polling a cursor that's not currently executing is an error
self.assertRaises(psycopg2.ProgrammingError, cur2.poll)
- self.wait_for_query(cur1)
+ self.wait(cur1)
self.assertEquals(cur1.fetchone()[0], 1)
def test_async_fetch_wrong_cursor(self):
@@ -332,7 +331,7 @@ class AsyncTests(unittest.TestCase):
cur2 = self.conn.cursor()
cur1.execute("select 1")
- self.wait_for_query(cur1)
+ self.wait(cur1)
self.assertFalse(self.conn.executing())
# fetching from a cursor with no results is an error
self.assertRaises(psycopg2.ProgrammingError, cur2.fetchone)