@@ -121,7 +121,6 @@ def __init__(self):
121
121
self .sessions_enabled = False
122
122
self .client = None # type: ignore
123
123
self .conn_lock = threading .Lock ()
124
- self .is_data_lake = False
125
124
self .load_balancer = TEST_LOADBALANCER
126
125
self ._fips_enabled = None
127
126
if self .load_balancer :
@@ -199,16 +198,6 @@ def _init_client(self):
199
198
self .mongoses = []
200
199
self .connection_attempts = []
201
200
self .client = self ._connect (host , port )
202
- if self .client is not None :
203
- # Return early when connected to dataLake as mongohoused does not
204
- # support the getCmdLineOpts command and is tested without TLS.
205
- if os .environ .get ("TEST_DATA_LAKE" ):
206
- self .is_data_lake = True
207
- self .auth_enabled = True
208
- self .client .close ()
209
- self .client = self ._connect (host , port , username = db_user , password = db_pwd )
210
- self .connected = True
211
- return
212
201
213
202
if HAVE_SSL and not self .client :
214
203
# Is MongoDB configured for SSL?
@@ -501,14 +490,6 @@ def require_connection(self, func):
501
490
func = func ,
502
491
)
503
492
504
- def require_data_lake (self , func ):
505
- """Run a test only if we are connected to Atlas Data Lake."""
506
- return self ._require (
507
- lambda : self .is_data_lake ,
508
- "Not connected to Atlas Data Lake on self.pair" ,
509
- func = func ,
510
- )
511
-
512
493
def require_version_min (self , * ver ):
513
494
"""Run a test only if the server version is at least ``version``."""
514
495
other_version = Version (* ver )
@@ -1230,21 +1211,6 @@ def teardown():
1230
1211
garbage .append (f" gc.get_referrers: { gc .get_referrers (g )!r} " )
1231
1212
if garbage :
1232
1213
raise AssertionError ("\n " .join (garbage ))
1233
- c = client_context .client
1234
- if c :
1235
- if not client_context .is_data_lake :
1236
- try :
1237
- c .drop_database ("pymongo-pooling-tests" )
1238
- c .drop_database ("pymongo_test" )
1239
- c .drop_database ("pymongo_test1" )
1240
- c .drop_database ("pymongo_test2" )
1241
- c .drop_database ("pymongo_test_mike" )
1242
- c .drop_database ("pymongo_test_bernie" )
1243
- except AutoReconnect :
1244
- # PYTHON-4982
1245
- if sys .implementation .name .lower () != "pypy" :
1246
- raise
1247
- c .close ()
1248
1214
print_running_clients ()
1249
1215
1250
1216
0 commit comments