PYTHON-5331 Convert stable api and storage tests to new task pattern (#2295)
This commit is contained in:
parent
5f956210f8
commit
0f37bfd7a1
@ -143,6 +143,7 @@ functions:
|
||||
- NO_EXT
|
||||
- COMPRESSORS
|
||||
- MONGODB_API_VERSION
|
||||
- REQUIRE_API_VERSION
|
||||
- DEBUG_LOG
|
||||
- ORCHESTRATION_FILE
|
||||
- OCSP_SERVER_TYPE
|
||||
|
||||
@ -792,71 +792,36 @@ buildvariants:
|
||||
PYTHON_BINARY: /opt/python/3.13/bin/python3
|
||||
|
||||
# Stable api tests
|
||||
- name: stable-api-require-v1-rhel8-python3.9-auth
|
||||
- name: stable-api-require-v1-rhel8-auth
|
||||
tasks:
|
||||
- name: "!.replica_set .5.0 .noauth .nossl .sync_async"
|
||||
- name: "!.replica_set .6.0 .noauth .nossl .sync_async"
|
||||
- name: "!.replica_set .7.0 .noauth .nossl .sync_async"
|
||||
- name: "!.replica_set .8.0 .noauth .nossl .sync_async"
|
||||
- name: "!.replica_set .rapid .noauth .nossl .sync_async"
|
||||
- name: "!.replica_set .latest .noauth .nossl .sync_async"
|
||||
display_name: Stable API require v1 RHEL8 Python3.9 Auth
|
||||
- name: .standard-linux !.replica_set-noauth-ssl .server-5.0
|
||||
- name: .standard-linux !.replica_set-noauth-ssl .server-6.0
|
||||
- name: .standard-linux !.replica_set-noauth-ssl .server-7.0
|
||||
- name: .standard-linux !.replica_set-noauth-ssl .server-8.0
|
||||
- name: .standard-linux !.replica_set-noauth-ssl .server-rapid
|
||||
- name: .standard-linux !.replica_set-noauth-ssl .server-latest
|
||||
display_name: Stable API require v1 RHEL8 Auth
|
||||
run_on:
|
||||
- rhel87-small
|
||||
expansions:
|
||||
AUTH: auth
|
||||
REQUIRE_API_VERSION: "1"
|
||||
MONGODB_API_VERSION: "1"
|
||||
PYTHON_BINARY: /opt/python/3.9/bin/python3
|
||||
tags: [versionedApi_tag]
|
||||
- name: stable-api-accept-v2-rhel8-python3.9-auth
|
||||
- name: stable-api-accept-v2-rhel8-auth
|
||||
tasks:
|
||||
- name: .standalone .5.0 .noauth .nossl .sync_async
|
||||
- name: .standalone .6.0 .noauth .nossl .sync_async
|
||||
- name: .standalone .7.0 .noauth .nossl .sync_async
|
||||
- name: .standalone .8.0 .noauth .nossl .sync_async
|
||||
- name: .standalone .rapid .noauth .nossl .sync_async
|
||||
- name: .standalone .latest .noauth .nossl .sync_async
|
||||
display_name: Stable API accept v2 RHEL8 Python3.9 Auth
|
||||
- name: .standard-linux .server-5.0 .standalone-noauth-nossl
|
||||
- name: .standard-linux .server-6.0 .standalone-noauth-nossl
|
||||
- name: .standard-linux .server-7.0 .standalone-noauth-nossl
|
||||
- name: .standard-linux .server-8.0 .standalone-noauth-nossl
|
||||
- name: .standard-linux .server-rapid .standalone-noauth-nossl
|
||||
- name: .standard-linux .server-latest .standalone-noauth-nossl
|
||||
display_name: Stable API accept v2 RHEL8 Auth
|
||||
run_on:
|
||||
- rhel87-small
|
||||
expansions:
|
||||
AUTH: auth
|
||||
ORCHESTRATION_FILE: versioned-api-testing.json
|
||||
PYTHON_BINARY: /opt/python/3.9/bin/python3
|
||||
tags: [versionedApi_tag]
|
||||
- name: stable-api-require-v1-rhel8-python3.13-auth
|
||||
tasks:
|
||||
- name: "!.replica_set .5.0 .noauth .nossl .sync_async"
|
||||
- name: "!.replica_set .6.0 .noauth .nossl .sync_async"
|
||||
- name: "!.replica_set .7.0 .noauth .nossl .sync_async"
|
||||
- name: "!.replica_set .8.0 .noauth .nossl .sync_async"
|
||||
- name: "!.replica_set .rapid .noauth .nossl .sync_async"
|
||||
- name: "!.replica_set .latest .noauth .nossl .sync_async"
|
||||
display_name: Stable API require v1 RHEL8 Python3.13 Auth
|
||||
run_on:
|
||||
- rhel87-small
|
||||
expansions:
|
||||
AUTH: auth
|
||||
REQUIRE_API_VERSION: "1"
|
||||
MONGODB_API_VERSION: "1"
|
||||
PYTHON_BINARY: /opt/python/3.13/bin/python3
|
||||
tags: [versionedApi_tag]
|
||||
- name: stable-api-accept-v2-rhel8-python3.13-auth
|
||||
tasks:
|
||||
- name: .standalone .5.0 .noauth .nossl .sync_async
|
||||
- name: .standalone .6.0 .noauth .nossl .sync_async
|
||||
- name: .standalone .7.0 .noauth .nossl .sync_async
|
||||
- name: .standalone .8.0 .noauth .nossl .sync_async
|
||||
- name: .standalone .rapid .noauth .nossl .sync_async
|
||||
- name: .standalone .latest .noauth .nossl .sync_async
|
||||
display_name: Stable API accept v2 RHEL8 Python3.13 Auth
|
||||
run_on:
|
||||
- rhel87-small
|
||||
expansions:
|
||||
AUTH: auth
|
||||
ORCHESTRATION_FILE: versioned-api-testing.json
|
||||
PYTHON_BINARY: /opt/python/3.13/bin/python3
|
||||
tags: [versionedApi_tag]
|
||||
|
||||
# Standard nonlinux tests
|
||||
@ -896,30 +861,19 @@ buildvariants:
|
||||
tags: [standard-non-linux]
|
||||
|
||||
# Storage engine tests
|
||||
- name: storage-inmemory-rhel8-python3.9
|
||||
- name: storage-inmemory-rhel8
|
||||
tasks:
|
||||
- name: .standalone .noauth .nossl .4.0 .sync_async
|
||||
- name: .standalone .noauth .nossl .4.2 .sync_async
|
||||
- name: .standalone .noauth .nossl .4.4 .sync_async
|
||||
- name: .standalone .noauth .nossl .5.0 .sync_async
|
||||
- name: .standalone .noauth .nossl .6.0 .sync_async
|
||||
- name: .standalone .noauth .nossl .7.0 .sync_async
|
||||
- name: .standalone .noauth .nossl .8.0 .sync_async
|
||||
- name: .standalone .noauth .nossl .rapid .sync_async
|
||||
- name: .standalone .noauth .nossl .latest .sync_async
|
||||
display_name: Storage InMemory RHEL8 Python3.9
|
||||
- name: .standard-linux .standalone-noauth-nossl
|
||||
display_name: Storage InMemory RHEL8
|
||||
run_on:
|
||||
- rhel87-small
|
||||
expansions:
|
||||
STORAGE_ENGINE: inmemory
|
||||
PYTHON_BINARY: /opt/python/3.9/bin/python3
|
||||
- name: storage-mmapv1-rhel8-python3.9
|
||||
- name: storage-mmapv1-rhel8
|
||||
tasks:
|
||||
- name: .standalone .4.0 .noauth .nossl .sync_async
|
||||
- name: .replica_set .4.0 .noauth .nossl .sync_async
|
||||
display_name: Storage MMAPv1 RHEL8 Python3.9
|
||||
- name: .standard-linux !.sharded_cluster-auth-ssl .server-4.0
|
||||
display_name: Storage MMAPv1 RHEL8
|
||||
run_on:
|
||||
- rhel87-small
|
||||
expansions:
|
||||
STORAGE_ENGINE: mmapv1
|
||||
PYTHON_BINARY: /opt/python/3.9/bin/python3
|
||||
|
||||
@ -283,20 +283,15 @@ def create_storage_engine_variants():
|
||||
engines = ["InMemory", "MMAPv1"]
|
||||
variants = []
|
||||
for engine in engines:
|
||||
python = CPYTHONS[0]
|
||||
expansions = dict(STORAGE_ENGINE=engine.lower())
|
||||
if engine == engines[0]:
|
||||
tasks = [f".standalone .noauth .nossl .{v} .sync_async" for v in ALL_VERSIONS]
|
||||
tasks = [".standard-linux .standalone-noauth-nossl"]
|
||||
else:
|
||||
# MongoDB 4.2 drops support for MMAPv1
|
||||
versions = get_versions_until("4.0")
|
||||
tasks = [f".standalone .{v} .noauth .nossl .sync_async" for v in versions] + [
|
||||
f".replica_set .{v} .noauth .nossl .sync_async" for v in versions
|
||||
]
|
||||
display_name = get_variant_name(f"Storage {engine}", host, python=python)
|
||||
variant = create_variant(
|
||||
tasks, display_name, host=host, python=python, expansions=expansions
|
||||
)
|
||||
tasks = [f".standard-linux !.sharded_cluster-auth-ssl .server-{v}" for v in versions]
|
||||
display_name = get_variant_name(f"Storage {engine}", host)
|
||||
variant = create_variant(tasks, display_name, host=host, expansions=expansions)
|
||||
variants.append(variant)
|
||||
return variants
|
||||
|
||||
@ -308,7 +303,7 @@ def create_stable_api_variants():
|
||||
types = ["require v1", "accept v2"]
|
||||
|
||||
# All python versions across platforms.
|
||||
for python, test_type in product(MIN_MAX_PYTHON, types):
|
||||
for test_type in types:
|
||||
expansions = dict(AUTH="auth")
|
||||
# Test against a cluster with requireApiVersion=1.
|
||||
if test_type == types[0]:
|
||||
@ -318,7 +313,8 @@ def create_stable_api_variants():
|
||||
# MONGODB_API_VERSION is the apiVersion to use in the test suite.
|
||||
expansions["MONGODB_API_VERSION"] = "1"
|
||||
tasks = [
|
||||
f"!.replica_set .{v} .noauth .nossl .sync_async" for v in get_versions_from("5.0")
|
||||
f".standard-linux !.replica_set-noauth-ssl .server-{v}"
|
||||
for v in get_versions_from("5.0")
|
||||
]
|
||||
else:
|
||||
# Test against a cluster with acceptApiVersion2 but without
|
||||
@ -326,13 +322,12 @@ def create_stable_api_variants():
|
||||
# clients created in the test suite.
|
||||
expansions["ORCHESTRATION_FILE"] = "versioned-api-testing.json"
|
||||
tasks = [
|
||||
f".standalone .{v} .noauth .nossl .sync_async" for v in get_versions_from("5.0")
|
||||
f".standard-linux .server-{v} .standalone-noauth-nossl"
|
||||
for v in get_versions_from("5.0")
|
||||
]
|
||||
base_display_name = f"Stable API {test_type}"
|
||||
display_name = get_variant_name(base_display_name, host, python=python, **expansions)
|
||||
variant = create_variant(
|
||||
tasks, display_name, host=host, python=python, tags=tags, expansions=expansions
|
||||
)
|
||||
display_name = get_variant_name(base_display_name, host, **expansions)
|
||||
variant = create_variant(tasks, display_name, host=host, tags=tags, expansions=expansions)
|
||||
variants.append(variant)
|
||||
|
||||
return variants
|
||||
@ -1164,6 +1159,7 @@ def create_run_tests_func():
|
||||
"NO_EXT",
|
||||
"COMPRESSORS",
|
||||
"MONGODB_API_VERSION",
|
||||
"REQUIRE_API_VERSION",
|
||||
"DEBUG_LOG",
|
||||
"ORCHESTRATION_FILE",
|
||||
"OCSP_SERVER_TYPE",
|
||||
|
||||
Loading…
Reference in New Issue
Block a user