Skip to content

Commit

Permalink
chore: setup auto-update when testing auto-update, even in CI. (#6651)
Browse files Browse the repository at this point in the history
Setup auto-update when testing auto-update, even in CI.
  • Loading branch information
lerouxb authored Jan 23, 2025
1 parent 02f689b commit a831e7b
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
6 changes: 4 additions & 2 deletions packages/compass-e2e-tests/helpers/compass.ts
Original file line number Diff line number Diff line change
Expand Up @@ -636,8 +636,10 @@ async function startCompassElectron(

process.env.APP_ENV = 'webdriverio';
// For webdriverio env we are changing appName so that keychain records do not
// overlap with anything else
process.env.HADRON_PRODUCT_NAME_OVERRIDE = 'MongoDB Compass WebdriverIO';
// overlap with anything else. But leave it alone when testing auto-update.
if (!process.env.HADRON_AUTO_UPDATE_ENDPOINT_OVERRIDE) {
process.env.HADRON_PRODUCT_NAME_OVERRIDE = 'MongoDB Compass WebdriverIO';
}

// Guide cues might affect too many tests in a way where the auto showing of the cue prevents
// clicks from working on elements. Dealing with this case-by-case is way too much work, so
Expand Down
4 changes: 1 addition & 3 deletions packages/compass/src/main/application.ts
Original file line number Diff line number Diff line change
Expand Up @@ -160,9 +160,7 @@ class CompassApplication {

await this.setupCORSBypass();
void this.setupCompassAuthService();
// TODO(COMPASS-7618): For now don't setup auto-update in CI because the
// toasts will obscure other things which we don't expect yet.
if (!process.env.CI) {
if (!process.env.CI || process.env.HADRON_AUTO_UPDATE_ENDPOINT_OVERRIDE) {
this.setupAutoUpdate();
}
await setupCSFLELibrary();
Expand Down

0 comments on commit a831e7b

Please sign in to comment.