Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 27 additions & 0 deletions packages/compass-e2e-tests/tests/connection.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -429,6 +429,33 @@ describe('Connection screen', function () {
expect(result).to.have.property('ok', 1);
});

it('can connect to an Atlas with tlsUseSystemCA', async function () {
if (!hasAtlasEnvironmentVariables()) {
return this.skip();
}

const username = process.env.E2E_TESTS_ATLAS_USERNAME ?? '';
const password = process.env.E2E_TESTS_ATLAS_PASSWORD ?? '';
const host = process.env.E2E_TESTS_ATLAS_HOST ?? '';

await browser.connectWithConnectionForm({
scheme: 'MONGODB_SRV',
authMethod: 'DEFAULT',
defaultUsername: username,
defaultPassword: password,
hosts: [host],
sslConnection: 'ON',
useSystemCA: true,
});
// NB: The fact that we can use the shell is a regression test for COMPASS-5802.
const result = await browser.shellEval(
'db.runCommand({ connectionStatus: 1 })',
true
);
await new Promise((resolve) => setTimeout(resolve, 10000));
expect(result).to.have.property('ok', 1);
});

it('can connect to Atlas Serverless', async function () {
if (!hasAtlasEnvironmentVariables()) {
return this.skip();
Expand Down
1 change: 1 addition & 0 deletions packages/compass/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,7 @@
"**/win-export-certificate-and-key/**",
"**/macos-export-certificate-and-key/**",
"**/system-ca/**",
"**/node-forge/**",
"**/mongo_crypt_v1.*"
]
},
Expand Down