Skip to content

Commit dba0aa9

Browse files
authored
PYTHON-5472 Remove driver tests for Atlas Data Lake (mongodb#2542)
1 parent a7a645f commit dba0aa9

File tree

14 files changed

+1
-331
lines changed

14 files changed

+1
-331
lines changed

.evergreen/generated_configs/variants.yml

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -79,17 +79,6 @@ buildvariants:
7979
TEST_NAME: atlas_connect
8080
tags: [pr]
8181

82-
# Atlas data lake tests
83-
- name: atlas-data-lake-ubuntu-22
84-
tasks:
85-
- name: .test-no-orchestration
86-
display_name: Atlas Data Lake Ubuntu-22
87-
run_on:
88-
- ubuntu2204-small
89-
expansions:
90-
TEST_NAME: data_lake
91-
tags: [pr]
92-
9382
# Aws auth tests
9483
- name: auth-aws-ubuntu-20
9584
tasks:

.evergreen/resync-specs.sh

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -76,9 +76,6 @@ do
7676
auth)
7777
cpjson auth/tests/ auth
7878
;;
79-
atlas-data-lake-testing|data_lake)
80-
cpjson atlas-data-lake-testing/tests/ data_lake
81-
;;
8279
bson-binary-vector|bson_binary_vector)
8380
cpjson bson-binary-vector/tests/ bson_binary_vector
8481
;;

.evergreen/scripts/generate_config.py

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -322,14 +322,6 @@ def create_no_c_ext_variants():
322322
return [create_variant(tasks, display_name, host=host)]
323323

324324

325-
def create_atlas_data_lake_variants():
326-
host = HOSTS["ubuntu22"]
327-
tasks = [".test-no-orchestration"]
328-
expansions = dict(TEST_NAME="data_lake")
329-
display_name = get_variant_name("Atlas Data Lake", host)
330-
return [create_variant(tasks, display_name, tags=["pr"], host=host, expansions=expansions)]
331-
332-
333325
def create_mod_wsgi_variants():
334326
host = HOSTS["ubuntu22"]
335327
tasks = [".mod_wsgi"]

.evergreen/scripts/resync-all-specs.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,6 @@ def check_new_spec_directories(directory: pathlib.Path) -> list[str]:
5656
"client_side_operations_timeout": "csot",
5757
"mongodb_handshake": "handshake",
5858
"load_balancers": "load_balancer",
59-
"atlas_data_lake_testing": "atlas",
6059
"connection_monitoring_and_pooling": "connection_monitoring",
6160
"command_logging_and_monitoring": "command_logging",
6261
"initial_dns_seedlist_discovery": "srv_seedlist",

.evergreen/scripts/setup_tests.py

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -214,18 +214,8 @@ def handle_test_env() -> None:
214214
if key in os.environ:
215215
write_env(key, os.environ[key])
216216

217-
if test_name == "data_lake":
218-
# Stop any running mongo-orchestration which might be using the port.
219-
run_command(f"bash {DRIVERS_TOOLS}/.evergreen/stop-orchestration.sh")
220-
run_command(f"bash {DRIVERS_TOOLS}/.evergreen/atlas_data_lake/setup.sh")
221-
AUTH = "auth"
222-
223217
if AUTH != "noauth":
224-
if test_name == "data_lake":
225-
config = read_env(f"{DRIVERS_TOOLS}/.evergreen/atlas_data_lake/secrets-export.sh")
226-
DB_USER = config["ADL_USERNAME"]
227-
DB_PASSWORD = config["ADL_PASSWORD"]
228-
elif test_name == "auth_oidc":
218+
if test_name == "auth_oidc":
229219
DB_USER = config["OIDC_ADMIN_USER"]
230220
DB_PASSWORD = config["OIDC_ADMIN_PWD"]
231221
elif test_name == "search_index":

.evergreen/scripts/teardown_tests.py

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -57,10 +57,6 @@
5757

5858
teardown_mod_wsgi()
5959

60-
# Tear down data_lake if applicable.
61-
elif TEST_NAME == "data_lake":
62-
run_command(f"{DRIVERS_TOOLS}/.evergreen/atlas_data_lake/teardown.sh")
63-
6460
# Tear down coverage if applicable.
6561
if os.environ.get("COVERAGE"):
6662
shutil.rmtree(".pytest_cache", ignore_errors=True)

.evergreen/scripts/utils.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,6 @@ class Distro:
3333
"atlas_connect": "atlas_connect",
3434
"auth_aws": "auth_aws",
3535
"auth_oidc": "auth_oidc",
36-
"data_lake": "data_lake",
3736
"default": "",
3837
"default_async": "default_async",
3938
"default_sync": "default",
@@ -57,7 +56,6 @@ class Distro:
5756
"auth_oidc",
5857
"atlas_connect",
5958
"aws_lambda",
60-
"data_lake",
6159
"mockupdb",
6260
"ocsp",
6361
]

CONTRIBUTING.md

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -355,13 +355,6 @@ Note: these tests can only be run from an Evergreen Linux host that has the Pyth
355355
The `mode` can be `standalone` or `embedded`. For the `replica_set` version of the tests, use
356356
`TOPOLOGY=replica_set just run-server`.
357357

358-
### Atlas Data Lake tests.
359-
360-
You must have `docker` or `podman` installed locally.
361-
362-
- Run `just setup-tests data_lake`.
363-
- Run `just run-tests`.
364-
365358
### OCSP tests
366359

367360
- Export the orchestration file, e.g. `export ORCHESTRATION_FILE=rsa-basic-tls-ocsp-disableStapling.json`.

pyproject.toml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,6 @@ markers = [
134134
"auth: tests that rely on authentication",
135135
"ocsp: tests that rely on ocsp",
136136
"atlas_connect: tests that rely on an atlas connection",
137-
"data_lake: tests that rely on atlas data lake",
138137
"perf: benchmark tests",
139138
"search_index: search index helper tests",
140139
"kms: client-side field-level encryption tests using kms",

test/__init__.py

Lines changed: 0 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,6 @@ def __init__(self):
121121
self.sessions_enabled = False
122122
self.client = None # type: ignore
123123
self.conn_lock = threading.Lock()
124-
self.is_data_lake = False
125124
self.load_balancer = TEST_LOADBALANCER
126125
self._fips_enabled = None
127126
if self.load_balancer:
@@ -199,16 +198,6 @@ def _init_client(self):
199198
self.mongoses = []
200199
self.connection_attempts = []
201200
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
212201

213202
if HAVE_SSL and not self.client:
214203
# Is MongoDB configured for SSL?
@@ -501,14 +490,6 @@ def require_connection(self, func):
501490
func=func,
502491
)
503492

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-
512493
def require_version_min(self, *ver):
513494
"""Run a test only if the server version is at least ``version``."""
514495
other_version = Version(*ver)
@@ -1230,21 +1211,6 @@ def teardown():
12301211
garbage.append(f" gc.get_referrers: {gc.get_referrers(g)!r}")
12311212
if garbage:
12321213
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()
12481214
print_running_clients()
12491215

12501216

0 commit comments

Comments
 (0)