Skip to content

Commit 7916184

Browse files
authored
chore: use new mongodb-runner in place of custom test server script COMPASS-6942 (#4623)
1 parent 407a1a0 commit 7916184

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

43 files changed

+683
-2937
lines changed

.evergreen/config.json

+6-12
Original file line numberDiff line numberDiff line change
@@ -53,8 +53,7 @@
5353
{
5454
"name": "40x-enterprise",
5555
"vars": {
56-
"mongodb_version": "4.0.x",
57-
"mongodb_use_enterprise": "yes"
56+
"mongodb_version": "4.0.x-enterprise"
5857
},
5958
"skip_on": ["macos-1100", "macos-1100-arm64"],
6059
"//": "MongoDB 4.0 / 4.2 Enterprise doesn't work on Ubuntu 20.04 without additional dependencies installed, it's easier to use an older machine than install missing dependencies as machines we are using are stateful",
@@ -72,8 +71,7 @@
7271
{
7372
"name": "42x-enterprise",
7473
"vars": {
75-
"mongodb_version": "4.2.x",
76-
"mongodb_use_enterprise": "yes"
74+
"mongodb_version": "4.2.x-enterprise"
7775
},
7876
"skip_on": ["macos-1100", "macos-1100-arm64"],
7977
"run_on_override": {
@@ -90,8 +88,7 @@
9088
{
9189
"name": "44x-enterprise",
9290
"vars": {
93-
"mongodb_version": "4.4.x",
94-
"mongodb_use_enterprise": "yes"
91+
"mongodb_version": "4.4.x-enterprise"
9592
},
9693
"skip_on": ["macos-1100", "macos-1100-arm64"]
9794
},
@@ -105,8 +102,7 @@
105102
{
106103
"name": "5x-enterprise",
107104
"vars": {
108-
"mongodb_version": "5.x.x",
109-
"mongodb_use_enterprise": "yes"
105+
"mongodb_version": "5.x.x-enterprise"
110106
},
111107
"skip_on": ["macos-1100", "macos-1100-arm64"]
112108
},
@@ -119,15 +115,13 @@
119115
{
120116
"name": "60x-enterprise",
121117
"vars": {
122-
"mongodb_version": "6.0.x",
123-
"mongodb_use_enterprise": "yes"
118+
"mongodb_version": "6.0.x-enterprise"
124119
}
125120
},
126121
{
127122
"name": "latest",
128123
"vars": {
129-
"mongodb_version": "latest-alpha",
130-
"mongodb_use_enterprise": "yes"
124+
"mongodb_version": "latest-alpha-enterprise"
131125
},
132126
"skip_on": ["macos-1100", "macos-1100-arm64", "rhel76-large"]
133127
}

.evergreen/functions.yml

+6-11
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,7 @@ variables:
7272
DOWNLOAD_CENTER_AWS_SECRET_ACCESS_KEY: ${aws_secret_evergreen_integrations}
7373
EVERGREEN_BUCKET_NAME: mciuploads
7474
EVERGREEN_BUCKET_KEY_PREFIX: ${project}/${revision}_${revision_order_id}
75+
MONGODB_RUNNER_LOG_DIR: ${workdir}/src/.testserver/
7576

7677
# This is here with the variables because anchors aren't supported across includes
7778
post:
@@ -199,7 +200,7 @@ functions:
199200
<<: *compass-env
200201
DEBUG: ${debug|}
201202
MONGODB_VERSION: ${mongodb_version|}
202-
MONGODB_USE_ENTERPRISE: ${mongodb_use_enterprise|}
203+
MONGODB_RUNNER_VERSION: ${mongodb_version|}
203204
script: |
204205
set -e
205206
@@ -225,7 +226,7 @@ functions:
225226
<<: *compass-env
226227
DEBUG: ${debug|}
227228
MONGODB_VERSION: ${mongodb_version|}
228-
MONGODB_USE_ENTERPRISE: ${mongodb_use_enterprise|}
229+
MONGODB_RUNNER_VERSION: ${mongodb_version|}
229230
script: |
230231
set -e
231232
@@ -352,7 +353,7 @@ functions:
352353
<<: *compass-env
353354
DEBUG: ${debug|}
354355
MONGODB_VERSION: ${mongodb_version|}
355-
MONGODB_USE_ENTERPRISE: ${mongodb_use_enterprise|}
356+
MONGODB_RUNNER_VERSION: ${mongodb_version|}
356357
script: |
357358
set -e
358359
# Load environment variables
@@ -376,20 +377,14 @@ functions:
376377
COMPASS_APP_NAME: ${packagerOptions.name}
377378
DEBUG: ${debug|}
378379
MONGODB_VERSION: ${mongodb_version|}
379-
MONGODB_USE_ENTERPRISE: ${mongodb_use_enterprise|}
380+
MONGODB_RUNNER_VERSION: ${mongodb_version|}
380381
script: |
381382
set -e
382383
# Load environment variables
383384
eval $(.evergreen/print-compass-env.sh)
384385
source .evergreen/start-docker-envs.sh
385386
386-
MONGODB_TYPE="community";
387-
388-
if [[ "$MONGODB_USE_ENTERPRISE" == "yes" ]]; then
389-
MONGODB_TYPE="enterprise"
390-
fi
391-
392-
echo "Running tests against packaged app at $COMPASS_APP_PATH for MongoDB $MONGODB_VERSION ($MONGODB_TYPE)..."
387+
echo "Running tests against packaged app at $COMPASS_APP_PATH for MongoDB $MONGODB_VERSION..."
393388
394389
if [[ "$IS_OSX" == "true" ]]; then
395390
echo "Disabling keychain usage in Compass (TODO: https://jira.mongodb.org/browse/BUILD-14458)"

.evergreen/print-compass-env.js

-1
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,6 @@ function printCompassEnv() {
104104
printVar('IS_UBUNTU', process.env.IS_UBUNTU);
105105
printVar('DEBUG', process.env.DEBUG);
106106
printVar('MONGODB_VERSION', process.env.MONGODB_VERSION || process.env.MONGODB_DEFAULT_VERSION);
107-
printVar('MONGODB_USE_ENTERPRISE', process.env.MONGODB_USE_ENTERPRISE);
108107
}
109108

110109
printCompassEnv();

.evergreen/tasks.yml

+6-12
Original file line numberDiff line numberDiff line change
@@ -187,8 +187,7 @@ tasks:
187187
compass_distribution: compass
188188
- func: test-packaged-app
189189
vars:
190-
mongodb_version: '4.0.x'
191-
mongodb_use_enterprise: 'yes'
190+
mongodb_version: '4.0.x-enterprise'
192191
compass_distribution: compass
193192
debug: 'compass-e2e-tests*,electron*,hadron*,mongo*'
194193

@@ -228,8 +227,7 @@ tasks:
228227
compass_distribution: compass
229228
- func: test-packaged-app
230229
vars:
231-
mongodb_version: '4.2.x'
232-
mongodb_use_enterprise: 'yes'
230+
mongodb_version: '4.2.x-enterprise'
233231
compass_distribution: compass
234232
debug: 'compass-e2e-tests*,electron*,hadron*,mongo*'
235233

@@ -269,8 +267,7 @@ tasks:
269267
compass_distribution: compass
270268
- func: test-packaged-app
271269
vars:
272-
mongodb_version: '4.4.x'
273-
mongodb_use_enterprise: 'yes'
270+
mongodb_version: '4.4.x-enterprise'
274271
compass_distribution: compass
275272
debug: 'compass-e2e-tests*,electron*,hadron*,mongo*'
276273

@@ -310,8 +307,7 @@ tasks:
310307
compass_distribution: compass
311308
- func: test-packaged-app
312309
vars:
313-
mongodb_version: '5.x.x'
314-
mongodb_use_enterprise: 'yes'
310+
mongodb_version: '5.x.x-enterprise'
315311
compass_distribution: compass
316312
debug: 'compass-e2e-tests*,electron*,hadron*,mongo*'
317313

@@ -351,8 +347,7 @@ tasks:
351347
compass_distribution: compass
352348
- func: test-packaged-app
353349
vars:
354-
mongodb_version: '6.0.x'
355-
mongodb_use_enterprise: 'yes'
350+
mongodb_version: '6.0.x-enterprise'
356351
compass_distribution: compass
357352
debug: 'compass-e2e-tests*,electron*,hadron*,mongo*'
358353

@@ -372,7 +367,6 @@ tasks:
372367
compass_distribution: compass
373368
- func: test-packaged-app
374369
vars:
375-
mongodb_version: 'latest-alpha'
376-
mongodb_use_enterprise: 'yes'
370+
mongodb_version: 'latest-alpha-enterprise'
377371
compass_distribution: compass
378372
debug: 'compass-e2e-tests*,electron*,hadron*,mongo*'

.gitignore

-1
Original file line numberDiff line numberDiff line change
@@ -33,5 +33,4 @@ mongodb-crypt
3333
packages/*/.npmrc
3434
config/*/.npmrc
3535
.sbom
36-
.testserver
3736
.evergreen/logs

0 commit comments

Comments
 (0)