Skip to content

Commit a02b237

Browse files
committed
merge main
2 parents 365d22d + a929550 commit a02b237

File tree

153 files changed

+6557
-4360
lines changed

Some content is hidden

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

153 files changed

+6557
-4360
lines changed

.evergreen/buildvariants-and-tasks.in.yml

Lines changed: 14 additions & 51 deletions
Original file line numberDiff line numberDiff line change
@@ -60,39 +60,6 @@ const PACKAGE_BUILD_VARIANTS = [
6060
}
6161
];
6262
63-
const SMOKETEST_BUILD_VARIANTS = [
64-
{
65-
name: 'smoketest-ubuntu',
66-
display_name: 'Smoketest Ubuntu',
67-
run_on: 'ubuntu2004-large',
68-
depends_on: 'package-ubuntu',
69-
},
70-
{
71-
name: 'smoketest-windows',
72-
display_name: 'Smoketest Windows',
73-
run_on: 'windows-vsCurrent-large',
74-
depends_on: 'package-windows',
75-
},
76-
{
77-
name: 'smoketest-rhel',
78-
display_name: 'Smoketest RHEL',
79-
run_on: 'rhel80-large',
80-
depends_on: 'package-rhel',
81-
},
82-
{
83-
name: 'smoketest-macos-x64',
84-
display_name: 'Smoketest MacOS Intel',
85-
run_on: 'macos-14-gui',
86-
depends_on: 'package-macos-x64',
87-
},
88-
{
89-
name: 'smoketest-macos-arm',
90-
display_name: 'Smoketest MacOS Arm64',
91-
run_on: 'macos-14-arm64-gui',
92-
depends_on: 'package-macos-arm',
93-
}
94-
];
95-
9663
const TEST_PACKAGED_APP_BUILD_VARIANTS = [
9764
{
9865
name: 'test-packaged-app-ubuntu',
@@ -207,7 +174,7 @@ buildvariants:
207174
<% for (const buildVariant of PACKAGE_BUILD_VARIANTS) { %>
208175
- name: <%= buildVariant.name %>
209176
expansions:
210-
silk_asset_group: <%= buildVariant.silk_asset_group %>
177+
target_platform: <%= buildVariant.target_platform %>
211178
display_name: <%= buildVariant.display_name %>
212179
run_on: <%= buildVariant.run_on %>
213180
tasks:
@@ -216,18 +183,18 @@ buildvariants:
216183
<% } %>
217184
<% } %>
218185

219-
<% for (const buildVariant of SMOKETEST_BUILD_VARIANTS) { %>
220-
<% for (const distribution of ['compass']) { %>
221-
- name: <%= buildVariant.name %>-<%= distribution %>
222-
display_name: <%= buildVariant.display_name %> (<%= distribution %>)
223-
run_on: <%= buildVariant.run_on %>
186+
- name: smoketest-packaged-app
187+
display_name: Smoke Test via GitHub Actions
188+
run_on: ubuntu2004-large
224189
depends_on:
225-
- name: package-<%= distribution %>
226-
variant: <%= buildVariant.depends_on %>
190+
<% for (const distribution of COMPASS_DISTRIBUTIONS) { %>
191+
<% for (const buildVariant of PACKAGE_BUILD_VARIANTS) { %>
192+
- name: package-<%= distribution %>
193+
variant: <%= buildVariant.name %>
194+
<% } %>
195+
<% } %>
227196
tasks:
228-
- name: smoketest-<%= distribution %>
229-
<% } %>
230-
<% } %>
197+
- name: smoketest-packaged-app
231198

232199
- name: test-eol-servers
233200
display_name: Test EoL Servers
@@ -468,21 +435,17 @@ tasks:
468435
compass_distribution: <%= distribution %>
469436
<% } %>
470437

471-
<% for (const distribution of ['compass']) { %>
472-
- name: smoketest-<%= distribution %>
438+
- name: smoketest-packaged-app
473439
tags: ['required-for-publish', 'run-on-pr']
474440
commands:
475441
- func: prepare
476442
- func: install
477443
- func: bootstrap
478444
vars:
479-
scope: 'compass-e2e-tests'
480-
- func: smoketest-packaged-app
445+
scope: '@mongodb-js/compass-smoke-tests'
446+
- func: smoketest-on-github-actions
481447
vars:
482-
mongodb_version: <%= LATEST_MAINTAINED_SERVER_VERSION.version %>
483-
compass_distribution: <%= distribution %>
484448
debug: 'compass-e2e-tests*,electron*,hadron*,mongo*'
485-
<% } %>
486449

487450
<% for (const serverVersion of SERVER_VERSIONS) { %>
488451
<% for(const group of E2E_TEST_GROUPS) { %>

.evergreen/buildvariants-and-tasks.yml

Lines changed: 26 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -76,46 +76,42 @@ buildvariants:
7676
- name: package-compass
7777
- name: package-compass-isolated
7878
- name: package-compass-readonly
79-
- name: smoketest-ubuntu-compass
80-
display_name: Smoketest Ubuntu (compass)
79+
- name: smoketest-packaged-app
80+
display_name: Smoke Test via GitHub Actions
8181
run_on: ubuntu2004-large
8282
depends_on:
8383
- name: package-compass
8484
variant: package-ubuntu
85-
tasks:
86-
- name: smoketest-compass
87-
- name: smoketest-windows-compass
88-
display_name: Smoketest Windows (compass)
89-
run_on: windows-vsCurrent-large
90-
depends_on:
9185
- name: package-compass
9286
variant: package-windows
93-
tasks:
94-
- name: smoketest-compass
95-
- name: smoketest-rhel-compass
96-
display_name: Smoketest RHEL (compass)
97-
run_on: rhel80-large
98-
depends_on:
9987
- name: package-compass
10088
variant: package-rhel
101-
tasks:
102-
- name: smoketest-compass
103-
- name: smoketest-macos-x64-compass
104-
display_name: Smoketest MacOS Intel (compass)
105-
run_on: macos-14-gui
106-
depends_on:
10789
- name: package-compass
10890
variant: package-macos-x64
109-
tasks:
110-
- name: smoketest-compass
111-
- name: smoketest-macos-arm-compass
112-
display_name: Smoketest MacOS Arm64 (compass)
113-
run_on: macos-14-arm64-gui
114-
depends_on:
11591
- name: package-compass
11692
variant: package-macos-arm
93+
- name: package-compass-isolated
94+
variant: package-ubuntu
95+
- name: package-compass-isolated
96+
variant: package-windows
97+
- name: package-compass-isolated
98+
variant: package-rhel
99+
- name: package-compass-isolated
100+
variant: package-macos-x64
101+
- name: package-compass-isolated
102+
variant: package-macos-arm
103+
- name: package-compass-readonly
104+
variant: package-ubuntu
105+
- name: package-compass-readonly
106+
variant: package-windows
107+
- name: package-compass-readonly
108+
variant: package-rhel
109+
- name: package-compass-readonly
110+
variant: package-macos-x64
111+
- name: package-compass-readonly
112+
variant: package-macos-arm
117113
tasks:
118-
- name: smoketest-compass
114+
- name: smoketest-packaged-app
119115
- name: test-eol-servers
120116
display_name: Test EoL Servers
121117
run_on: ubuntu1804-large
@@ -508,7 +504,7 @@ tasks:
508504
- func: save-all-artifacts
509505
vars:
510506
compass_distribution: compass-readonly
511-
- name: smoketest-compass
507+
- name: smoketest-packaged-app
512508
tags:
513509
- required-for-publish
514510
- run-on-pr
@@ -517,11 +513,9 @@ tasks:
517513
- func: install
518514
- func: bootstrap
519515
vars:
520-
scope: compass-e2e-tests
521-
- func: smoketest-packaged-app
516+
scope: '@mongodb-js/compass-smoke-tests'
517+
- func: smoketest-on-github-actions
522518
vars:
523-
mongodb_version: 8.0.x-enterprise
524-
compass_distribution: compass
525519
debug: compass-e2e-tests*,electron*,hadron*,mongo*
526520
- name: test-server-40x-community-1
527521
tags:

.evergreen/functions.yml

Lines changed: 10 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -651,14 +651,12 @@ functions:
651651
652652
npm run --unsafe-perm --workspace compass-e2e-tests test-packaged-ci
653653
654-
smoketest-packaged-app:
654+
smoketest-on-github-actions:
655655
- command: github.generate_token
656656
params:
657-
owner: 10gen
658-
repo: compass-mongodb-com
659657
expansion_name: generated_token
660658
permissions: # optional
661-
contents: read
659+
actions: write
662660
- command: shell.exec
663661
# Fail the task if it's idle for 10 mins
664662
timeout_secs: 600
@@ -667,42 +665,19 @@ functions:
667665
shell: bash
668666
env:
669667
<<: *compass-env
670-
<<: *compass-e2e-secrets
671668
DEBUG: ${debug|}
672-
MONGODB_VERSION: ${mongodb_version|}
673-
MONGODB_RUNNER_VERSION: ${mongodb_version|}
674-
HADRON_DISTRIBUTION: ${compass_distribution}
669+
GITHUB_TOKEN: ${generated_token}
670+
GITHUB_PR_NUMBER: ${github_pr_number}
671+
EVERGREEN_TASK_URL: https://spruce.mongodb.com/task/${task_id}
675672
script: |
676673
set -e
677674
# Load environment variables
678675
eval $(.evergreen/print-compass-env.sh)
679-
680-
npm i -w packages/compass-smoke-tests https://x-access-token:${generated_token}@github.com/10gen/compass-mongodb-com --engine-strict=false
681-
682-
if [[ "$IS_WINDOWS" == "true" ]]; then
683-
npm run --unsafe-perm --workspace @mongodb-js/compass-smoke-tests start -- --package=windows_setup --tests time-to-first-query
684-
npm run --unsafe-perm --workspace @mongodb-js/compass-smoke-tests start -- --package=windows_zip --tests auto-update-from
685-
npm run --unsafe-perm --workspace @mongodb-js/compass-smoke-tests start -- --package=windows_msi --tests auto-update-from
686-
fi
687-
688-
if [[ "$IS_OSX" == "true" ]]; then
689-
echo "Disabling clipboard usage in e2e tests (TODO: https://jira.mongodb.org/browse/BUILD-14780)"
690-
export COMPASS_E2E_DISABLE_CLIPBOARD_USAGE="true"
691-
# NOTE: We're also skipping auto-update of the macOS app in CI
692-
# because it doesn't work. Running a different test to make sure it
693-
# can install and run successfully at least.
694-
npm run --unsafe-perm --workspace @mongodb-js/compass-smoke-tests start -- --package=osx_zip --tests=time-to-first-query
695-
npm run --unsafe-perm --workspace @mongodb-js/compass-smoke-tests start -- --package=osx_dmg --tests=time-to-first-query
696-
fi
697-
698-
if [[ "$IS_UBUNTU" == "true" ]]; then
699-
npm run --unsafe-perm --workspace @mongodb-js/compass-smoke-tests start -- --package=linux_deb --tests=time-to-first-query
700-
npm run --unsafe-perm --workspace @mongodb-js/compass-smoke-tests start -- --package=linux_tar --tests=time-to-first-query
701-
fi
702-
703-
if [[ "$IS_RHEL" == "true" ]]; then
704-
# npm run --unsafe-perm --workspace @mongodb-js/compass-smoke-tests start -- --package=linux_rpm --tests=time-to-first-query
705-
npm run --unsafe-perm --workspace @mongodb-js/compass-smoke-tests start -- --package=linux_tar --tests=time-to-first-query
676+
# Start the smoke tests on GitHub Actions and wait for successful completion
677+
if [[ "${requester}" == "github_pr" ]]; then
678+
npm run --workspace @mongodb-js/compass-smoke-tests start -- dispatch --github-pr-number ${github_pr_number}
679+
else
680+
npm run --workspace @mongodb-js/compass-smoke-tests start -- dispatch --ref ${branch_name}
706681
fi
707682
708683
test-web-sandbox:

.github/PULL_REQUEST_TEMPLATE.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,12 @@
1212
## Description
1313
<!--- Describe your changes in detail -->
1414
<!--- If applicable, describe (or illustrate) architecture flow -->
15+
<!--- If the UI changes in a non-trivial way, consider adding screenshots/video illustrating the new flows -->
1516

1617
### Checklist
1718
- [ ] New tests and/or benchmarks are included
1819
- [ ] Documentation is changed or added
20+
- [ ] If this change updates the UI, screenshots/videos are added and a design review is requested
1921
- [ ] I have signed the MongoDB Contributor License Agreement (https://www.mongodb.com/legal/contributor-agreement)
2022

2123
## Motivation and Context

0 commit comments

Comments
 (0)