PYTHON-5342 Fix test_dns_failures test (#2336)
This commit is contained in:
parent
d0b0dc3512
commit
5914ea0ff4
@ -20,7 +20,6 @@ import sys
|
||||
import time
|
||||
from test.utils_shared import FunctionCallRecorder
|
||||
from typing import Any
|
||||
from unittest import skipIf
|
||||
|
||||
sys.path[0:0] = [""]
|
||||
|
||||
@ -92,7 +91,6 @@ class SrvPollingKnobs:
|
||||
self.disable()
|
||||
|
||||
|
||||
@skipIf(not _IS_SYNC and sys.platform == "win32", "PYTHON-5342 known issue on Windows")
|
||||
class TestSrvPolling(AsyncPyMongoTestCase):
|
||||
BASE_SRV_RESPONSE = [
|
||||
("localhost.test.build.10gen.cc", 27017),
|
||||
@ -186,6 +184,9 @@ class TestSrvPolling(AsyncPyMongoTestCase):
|
||||
):
|
||||
await assertion_method(expected_response, client)
|
||||
|
||||
# Close the client early to avoid affecting the next scenario run.
|
||||
await client.close()
|
||||
|
||||
async def test_addition(self):
|
||||
response = self.BASE_SRV_RESPONSE[:]
|
||||
response.append(("localhost.test.build.10gen.cc", 27019))
|
||||
|
||||
@ -20,7 +20,6 @@ import sys
|
||||
import time
|
||||
from test.utils_shared import FunctionCallRecorder
|
||||
from typing import Any
|
||||
from unittest import skipIf
|
||||
|
||||
sys.path[0:0] = [""]
|
||||
|
||||
@ -92,7 +91,6 @@ class SrvPollingKnobs:
|
||||
self.disable()
|
||||
|
||||
|
||||
@skipIf(not _IS_SYNC and sys.platform == "win32", "PYTHON-5342 known issue on Windows")
|
||||
class TestSrvPolling(PyMongoTestCase):
|
||||
BASE_SRV_RESPONSE = [
|
||||
("localhost.test.build.10gen.cc", 27017),
|
||||
@ -186,6 +184,9 @@ class TestSrvPolling(PyMongoTestCase):
|
||||
):
|
||||
assertion_method(expected_response, client)
|
||||
|
||||
# Close the client early to avoid affecting the next scenario run.
|
||||
client.close()
|
||||
|
||||
def test_addition(self):
|
||||
response = self.BASE_SRV_RESPONSE[:]
|
||||
response.append(("localhost.test.build.10gen.cc", 27019))
|
||||
|
||||
Loading…
Reference in New Issue
Block a user