Skip to content

Commit c64d541

Browse files
committed
PYTHON-4892 Use shrub.py for remaining axes
1 parent 4003edf commit c64d541

File tree

2 files changed

+115
-162
lines changed

2 files changed

+115
-162
lines changed

.evergreen/config.yml

Lines changed: 65 additions & 160 deletions
Original file line numberDiff line numberDiff line change
@@ -2112,47 +2112,6 @@ axes:
21122112
AUTH: "noauth"
21132113
SSL: "nossl"
21142114

2115-
# Choice of MongoDB server version
2116-
- id: mongodb-version
2117-
display_name: "MongoDB"
2118-
values:
2119-
- id: "4.0"
2120-
display_name: "MongoDB 4.0"
2121-
variables:
2122-
VERSION: "4.0"
2123-
- id: "4.2"
2124-
display_name: "MongoDB 4.2"
2125-
variables:
2126-
VERSION: "4.2"
2127-
- id: "4.4"
2128-
display_name: "MongoDB 4.4"
2129-
variables:
2130-
VERSION: "4.4"
2131-
- id: "5.0"
2132-
display_name: "MongoDB 5.0"
2133-
variables:
2134-
VERSION: "5.0"
2135-
- id: "6.0"
2136-
display_name: "MongoDB 6.0"
2137-
variables:
2138-
VERSION: "6.0"
2139-
- id: "7.0"
2140-
display_name: "MongoDB 7.0"
2141-
variables:
2142-
VERSION: "7.0"
2143-
- id: "8.0"
2144-
display_name: "MongoDB 8.0"
2145-
variables:
2146-
VERSION: "8.0"
2147-
- id: "latest"
2148-
display_name: "MongoDB latest"
2149-
variables:
2150-
VERSION: "latest"
2151-
- id: "rapid"
2152-
display_name: "MongoDB rapid"
2153-
variables:
2154-
VERSION: "rapid"
2155-
21562115
# Choice of Python runtime version
21572116
- id: python-version
21582117
display_name: "Python"
@@ -2188,93 +2147,6 @@ axes:
21882147
variables:
21892148
PYTHON_BINARY: "/opt/python/pypy3.10/bin/pypy3"
21902149

2191-
- id: python-version-windows
2192-
display_name: "Python"
2193-
values:
2194-
- id: "3.9"
2195-
display_name: "Python 3.9"
2196-
variables:
2197-
PYTHON_BINARY: "C:/python/Python39/python.exe"
2198-
- id: "3.10"
2199-
display_name: "Python 3.10"
2200-
variables:
2201-
PYTHON_BINARY: "C:/python/Python310/python.exe"
2202-
- id: "3.11"
2203-
display_name: "Python 3.11"
2204-
variables:
2205-
PYTHON_BINARY: "C:/python/Python311/python.exe"
2206-
- id: "3.12"
2207-
display_name: "Python 3.12"
2208-
variables:
2209-
PYTHON_BINARY: "C:/python/Python312/python.exe"
2210-
- id: "3.13"
2211-
display_name: "Python 3.13"
2212-
variables:
2213-
PYTHON_BINARY: "C:/python/Python313/python.exe"
2214-
2215-
- id: python-version-windows-32
2216-
display_name: "Python"
2217-
values:
2218-
2219-
2220-
- id: "3.9"
2221-
display_name: "32-bit Python 3.9"
2222-
variables:
2223-
PYTHON_BINARY: "C:/python/32/Python39/python.exe"
2224-
- id: "3.10"
2225-
display_name: "32-bit Python 3.10"
2226-
variables:
2227-
PYTHON_BINARY: "C:/python/32/Python310/python.exe"
2228-
- id: "3.11"
2229-
display_name: "32-bit Python 3.11"
2230-
variables:
2231-
PYTHON_BINARY: "C:/python/32/Python311/python.exe"
2232-
- id: "3.12"
2233-
display_name: "32-bit Python 3.12"
2234-
variables:
2235-
PYTHON_BINARY: "C:/python/32/Python312/python.exe"
2236-
- id: "3.13"
2237-
display_name: "32-bit Python 3.13"
2238-
variables:
2239-
PYTHON_BINARY: "C:/python/32/Python313/python.exe"
2240-
2241-
# Choice of mod_wsgi version
2242-
- id: mod-wsgi-version
2243-
display_name: "mod_wsgi version"
2244-
values:
2245-
- id: "4"
2246-
display_name: "mod_wsgi 4.x"
2247-
variables:
2248-
MOD_WSGI_VERSION: "4"
2249-
2250-
# Run with test commands disabled on server?
2251-
- id: disableTestCommands
2252-
display_name: Disable test commands
2253-
values:
2254-
- id: disabled
2255-
display_name: disabled
2256-
variables:
2257-
DISABLE_TEST_COMMANDS: "1"
2258-
2259-
# Generate coverage report?
2260-
- id: coverage
2261-
display_name: "Coverage"
2262-
values:
2263-
- id: "coverage"
2264-
display_name: "Coverage"
2265-
tags: ["coverage_tag"]
2266-
variables:
2267-
COVERAGE: "coverage"
2268-
2269-
- id: serverless
2270-
display_name: "Serverless"
2271-
values:
2272-
- id: "enabled"
2273-
display_name: "Serverless"
2274-
variables:
2275-
test_serverless: true
2276-
batchtime: 10080 # 7 days
2277-
22782150
buildvariants:
22792151
# Server Tests for RHEL8.
22802152
- name: test-rhel8-py3.9-auth-ssl-cov
@@ -3530,6 +3402,71 @@ buildvariants:
35303402
expansions:
35313403
PYTHON_BINARY: /opt/python/3.13/bin/python3
35323404

3405+
# Mod_wsgi tests.
3406+
- name: mod_wsgi-ubuntu-22-py3.9
3407+
tasks:
3408+
- name: mod-wsgi-standalone
3409+
- name: mod-wsgi-replica-set
3410+
- name: mod-wsgi-embedded-mode-standalone
3411+
- name: mod-wsgi-embedded-mode-replica-set
3412+
display_name: mod_wsgi Ubuntu-22 py3.9
3413+
run_on:
3414+
- ubuntu2204-small
3415+
expansions:
3416+
MOD_WSGI_VERSION: "4"
3417+
PYTHON_BINARY: /opt/python/3.9/bin/python3
3418+
- name: mod_wsgi-ubuntu-22-py3.13
3419+
tasks:
3420+
- name: mod-wsgi-standalone
3421+
- name: mod-wsgi-replica-set
3422+
- name: mod-wsgi-embedded-mode-standalone
3423+
- name: mod-wsgi-embedded-mode-replica-set
3424+
display_name: mod_wsgi Ubuntu-22 py3.13
3425+
run_on:
3426+
- ubuntu2204-small
3427+
expansions:
3428+
MOD_WSGI_VERSION: "4"
3429+
PYTHON_BINARY: /opt/python/3.13/bin/python3
3430+
3431+
# Disable test commands variants.
3432+
- name: disable-test-commands-rhel8-py3.9
3433+
tasks:
3434+
- name: .latest
3435+
display_name: Disable test commands RHEL8 py3.9
3436+
run_on:
3437+
- rhel87-small
3438+
expansions:
3439+
AUTH: auth
3440+
SSL: ssl
3441+
DISABLE_TEST_COMMANDS: "1"
3442+
PYTHON_BINARY: /opt/python/3.9/bin/python3
3443+
3444+
# Serverless variants.
3445+
- name: serverless-rhel8-py3.9
3446+
tasks:
3447+
- name: serverless_task_group
3448+
display_name: Serverless RHEL8 py3.9
3449+
run_on:
3450+
- rhel87-small
3451+
batchtime: 10080
3452+
expansions:
3453+
test_serverless: "true"
3454+
AUTH: auth
3455+
SSL: ssl
3456+
PYTHON_BINARY: /opt/python/3.9/bin/python3
3457+
- name: serverless-rhel8-py3.13
3458+
tasks:
3459+
- name: serverless_task_group
3460+
display_name: Serverless RHEL8 py3.13
3461+
run_on:
3462+
- rhel87-small
3463+
batchtime: 10080
3464+
expansions:
3465+
test_serverless: "true"
3466+
AUTH: auth
3467+
SSL: ssl
3468+
PYTHON_BINARY: /opt/python/3.13/bin/python3
3469+
35333470
- matrix_name: "tests-fips"
35343471
matrix_spec:
35353472
platform:
@@ -3562,16 +3499,6 @@ buildvariants:
35623499
tasks:
35633500
- ".5.0"
35643501

3565-
# enableTestCommands=0 tests on RHEL 8.4 (x86_64) with Python 3.9.
3566-
- matrix_name: "test-disableTestCommands"
3567-
matrix_spec:
3568-
platform: rhel8
3569-
disableTestCommands: "*"
3570-
python-version: "3.9"
3571-
display_name: "Disable test commands ${python-version} ${platform}"
3572-
tasks:
3573-
- ".latest"
3574-
35753502
- matrix_name: "test-search-index-helpers"
35763503
matrix_spec:
35773504
platform: rhel8
@@ -3580,18 +3507,6 @@ buildvariants:
35803507
tasks:
35813508
- name: "test_atlas_task_group_search_indexes"
35823509

3583-
- matrix_name: "tests-mod-wsgi"
3584-
matrix_spec:
3585-
platform: ubuntu-22.04
3586-
python-version: ["3.9", "3.10", "3.11", "3.12", "3.13"]
3587-
mod-wsgi-version: "*"
3588-
display_name: "${mod-wsgi-version} ${python-version} ${platform}"
3589-
tasks:
3590-
- name: "mod-wsgi-standalone"
3591-
- name: "mod-wsgi-replica-set"
3592-
- name: "mod-wsgi-embedded-mode-standalone"
3593-
- name: "mod-wsgi-embedded-mode-replica-set"
3594-
35953510
- matrix_name: "mockupdb-tests"
35963511
matrix_spec:
35973512
platform: rhel8
@@ -3630,16 +3545,6 @@ buildvariants:
36303545
tasks:
36313546
- name: "atlas-connect"
36323547

3633-
- matrix_name: "serverless"
3634-
matrix_spec:
3635-
platform: rhel8
3636-
python-version: "*"
3637-
auth-ssl: auth-ssl
3638-
serverless: "enabled"
3639-
display_name: "${serverless} ${python-version} ${platform}"
3640-
tasks:
3641-
- "serverless_task_group"
3642-
36433548
# OCSP test matrix.
36443549
- name: ocsp-test-rhel8-v4.4-py3.9
36453550
tasks:

.evergreen/scripts/generate_config.py

Lines changed: 50 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,7 @@ class Host:
5454
HOSTS["win32"] = Host("win32", "windows-64-vsMulti-small", "Win32")
5555
HOSTS["macos"] = Host("macos", "macos-14", "macOS")
5656
HOSTS["macos-arm64"] = Host("macos-arm64", "macos-14-arm64", "macOS Arm64")
57+
HOSTS["ubuntu22"] = Host("ubuntu22", "ubuntu2204-small", "Ubuntu-22")
5758

5859

5960
##############
@@ -102,7 +103,7 @@ def get_python_binary(python: str, host: str) -> str:
102103
python = python.replace(".", "")
103104
return f"{base}/Python{python}/python.exe"
104105

105-
if host == "rhel8":
106+
if host in ["rhel8", "ubuntu22"]:
106107
return f"/opt/python/{python}/bin/python3"
107108

108109
if host in ["macos", "macos-arm64"]:
@@ -558,10 +559,57 @@ def generate_atlas_data_lake_variants():
558559
return variants
559560

560561

562+
def generate_mod_wsgi_variants():
563+
variants = []
564+
host = "ubuntu22"
565+
tasks = [
566+
"mod-wsgi-standalone",
567+
"mod-wsgi-replica-set",
568+
"mod-wsgi-embedded-mode-standalone",
569+
"mod-wsgi-embedded-mode-replica-set",
570+
]
571+
expansions = dict(MOD_WSGI_VERSION="4")
572+
for python in MIN_MAX_PYTHON:
573+
display_name = get_display_name("mod_wsgi", host, python=python)
574+
variant = create_variant(
575+
tasks, display_name, host=host, python=python, expansions=expansions
576+
)
577+
variants.append(variant)
578+
return variants
579+
580+
581+
def generate_disable_test_commands_variants():
582+
host = "rhel8"
583+
expansions = dict(AUTH="auth", SSL="ssl", DISABLE_TEST_COMMANDS="1")
584+
python = CPYTHONS[0]
585+
display_name = get_display_name("Disable test commands", host, python=python)
586+
tasks = [".latest"]
587+
return [create_variant(tasks, display_name, host=host, python=python, expansions=expansions)]
588+
589+
590+
def generate_serverless_variants():
591+
host = "rhel8"
592+
batchtime = BATCHTIME_WEEK
593+
expansions = dict(test_serverless="true", AUTH="auth", SSL="ssl")
594+
tasks = ["serverless_task_group"]
595+
base_name = "Serverless"
596+
return [
597+
create_variant(
598+
tasks,
599+
get_display_name(base_name, host, python=python),
600+
host=host,
601+
python=python,
602+
expansions=expansions,
603+
batchtime=batchtime,
604+
)
605+
for python in MIN_MAX_PYTHON
606+
]
607+
608+
561609
##################
562610
# Generate Config
563611
##################
564612

565-
variants = generate_atlas_data_lake_variants()
613+
variants = generate_serverless_variants()
566614
# print(len(variants))
567615
generate_yaml(variants=variants)

0 commit comments

Comments
 (0)