From c2b4050f765303ef31b9a7dc67c68cd8da7ccced Mon Sep 17 00:00:00 2001 From: Shane Harvey Date: Wed, 25 Oct 2023 11:43:26 -0700 Subject: [PATCH] PYTHON-4010 Fix test_timeout_kills_cursor_asynchronously --- test/test_cursor.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/test/test_cursor.py b/test/test_cursor.py index 212de4d287..7b10c2cac6 100644 --- a/test/test_cursor.py +++ b/test/test_cursor.py @@ -1259,8 +1259,8 @@ def test_timeout_kills_cursor_asynchronously(self): def assertCursorKilled(): wait_until( - lambda: len(client._MongoClient__kill_cursors_queue) == 0, - "waited for all killCursor requests to complete", + lambda: len(listener.succeeded_events), + "find successful killCursors command", ) self.assertEqual(1, len(listener.started_events))