Skip to content

Commit e1de8be

Browse files
author
A. Jesse Jiryu Davis
committed
Increase delay in test_pool to avoid race condition, and remove obsolete version-check
1 parent 3da05fb commit e1de8be

File tree

1 file changed

+2
-6
lines changed

1 file changed

+2
-6
lines changed

test/test_pooling_base.py

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -776,10 +776,6 @@ def _test_pool(self, use_request):
776776
)
777777

778778
db = cx.pymongo_test
779-
if not version.at_least(db.connection, (1, 7, 2)):
780-
raise SkipTest("Need at least MongoDB version 1.7.2 to use"
781-
" db.eval(nolock=True)")
782-
783779
db.test.remove(safe=True)
784780
db.test.insert({'_id': 1}, safe=True)
785781

@@ -806,8 +802,8 @@ def find_slow():
806802

807803
history.append('find_slow start')
808804

809-
# Javascript function that pauses 5 seconds.
810-
fn = delay(5)
805+
# Javascript function that pauses N seconds per document
806+
fn = delay(10)
811807
self.assertEqual(1, db.test.find({"$where": fn}).count())
812808

813809
history.append('find_slow done')

0 commit comments

Comments
 (0)