Skip to content

Commit 208c92c

Browse files
committed
Merge branch 'main' of github.com:mongodb-js/mongosh into gagik/e2e-foliage
2 parents c6548c7 + 7c26c7a commit 208c92c

File tree

10 files changed

+60
-68
lines changed

10 files changed

+60
-68
lines changed

THIRD_PARTY_NOTICES.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
The following third-party software is used by and included in **mongosh**.
2-
This document was automatically generated on Sun Dec 15 2024.
2+
This document was automatically generated on Mon Dec 16 2024.
33

44
## List of dependencies
55

packages/e2e-tests/test/e2e-auth.spec.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -998,7 +998,7 @@ describe('Auth e2e', function () {
998998
],
999999
});
10001000
if (
1001-
(await preTestShell.waitForExit()) === 1 &&
1001+
(await preTestShell.waitForAnyExit()) === 1 &&
10021002
preTestShell.output.match(
10031003
/digital envelope routines::unsupported|SSL routines::library has no ciphers/
10041004
)
@@ -1022,7 +1022,7 @@ describe('Auth e2e', function () {
10221022
'SCRAM-SHA-1',
10231023
],
10241024
});
1025-
await shell.waitForExit();
1025+
await shell.waitForAnyExit();
10261026
try {
10271027
shell.assertContainsOutput(
10281028
'Auth mechanism SCRAM-SHA-1 is not supported in FIPS mode'
@@ -1109,7 +1109,7 @@ describe('Auth e2e', function () {
11091109
'GSSAPI',
11101110
],
11111111
});
1112-
await shell.waitForExit();
1112+
await shell.waitForAnyExit();
11131113
// Failing to auth with kerberos fails with different error messages on each OS.
11141114
// Sometimes in CI, it also fails because the server received kerberos
11151115
// credentials, most likely because of a successful login by another

packages/e2e-tests/test/e2e-direct.spec.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -344,7 +344,7 @@ describe('e2e direct connection', function () {
344344
const shell = this.startTestShell({
345345
args: ['--host', hostlist, 'admin'],
346346
});
347-
await shell.waitForExit();
347+
await shell.waitForAnyExit();
348348
shell.assertContainsOutput('MongoServerSelectionError');
349349
});
350350

packages/e2e-tests/test/e2e-oidc.spec.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -249,7 +249,7 @@ describe('OIDC auth e2e', function () {
249249
'--browser=false',
250250
],
251251
});
252-
await shell.waitForExit();
252+
await shell.waitForAnyExit();
253253
shell.assertContainsOutput(
254254
'Consider specifying --oidcFlows=auth-code,device-auth if you are running mongosh in an environment without browser access'
255255
);
@@ -405,7 +405,7 @@ describe('OIDC auth e2e', function () {
405405
MONGOSH_E2E_TEST_CURL_ALLOW_INVALID_TLS: '1',
406406
},
407407
});
408-
await shell.waitForExit();
408+
await shell.waitForAnyExit();
409409
// We cannot make the mongod server accept the mock IdP's certificate,
410410
// so the best we can verify here is that auth failed *on the server*
411411
shell.assertContainsOutput(/MongoServerError: Authentication failed/);
@@ -435,7 +435,7 @@ describe('OIDC auth e2e', function () {
435435
},
436436
});
437437

438-
await shell.waitForExit();
438+
await shell.waitForAnyExit();
439439
// We cannot make the mongod server accept the mock IdP's certificate,
440440
// so the best we can verify here is that auth failed *on the server*
441441
shell.assertContainsOutput(/MongoServerError: Authentication failed/);
@@ -499,7 +499,7 @@ describe('OIDC auth e2e', function () {
499499
'--eval=42',
500500
],
501501
});
502-
await shell.waitForExit();
502+
await shell.waitForSuccessfulExit();
503503

504504
shell.assertContainsOutput('BEGIN OIDC TOKEN DUMP');
505505
shell.assertContainsOutput('"tokenType": "Bearer"');
@@ -519,7 +519,7 @@ describe('OIDC auth e2e', function () {
519519
'--eval=42',
520520
],
521521
});
522-
await shell.waitForExit();
522+
await shell.waitForSuccessfulExit();
523523

524524
shell.assertContainsOutput('BEGIN OIDC TOKEN DUMP');
525525
shell.assertContainsOutput('"tokenType": "Bearer"');

packages/e2e-tests/test/e2e-proxy.spec.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -271,7 +271,7 @@ describe('e2e proxy support', function () {
271271
},
272272
});
273273

274-
const code = await shell.waitForExit();
274+
const code = await shell.waitForAnyExit();
275275
expect(code).to.equal(1);
276276
});
277277

@@ -622,7 +622,7 @@ describe('e2e proxy support', function () {
622622
},
623623
});
624624

625-
await shell.waitForExit();
625+
await shell.waitForAnyExit();
626626
// We cannot make the mongod server accept the mock IdP's certificate,
627627
// so the best we can verify here is that auth failed *on the server*
628628
shell.assertContainsOutput(/MongoServerError: Authentication failed/);

packages/e2e-tests/test/e2e-snippet.spec.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ describe('snippet integration tests', function () {
8787
'config.set("snippetIndexSourceURLs", "http://localhost:1/")'
8888
);
8989
shell.writeInputLine('exit');
90-
await shell.waitForExit();
90+
await shell.waitForSuccessfulExit();
9191

9292
shell = makeTestShell();
9393
await shell.waitForPrompt();

packages/e2e-tests/test/e2e-tls.spec.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -92,8 +92,8 @@ describe('e2e TLS', function () {
9292
});
9393
await shell.waitForPrompt();
9494
await shell.executeLine('db.shutdownServer({ force: true })');
95-
shell.kill();
96-
await shell.waitForExit();
95+
shell.writeInputLine('exit');
96+
await shell.waitForAnyExit(); // closing the server may lead to an error being displayed
9797
});
9898

9999
const server = startTestServer('e2e-tls-no-cli-valid-srv', {
@@ -399,8 +399,8 @@ describe('e2e TLS', function () {
399399
});
400400
await shell.waitForPrompt();
401401
await shell.executeLine('db.shutdownServer({ force: true })');
402-
shell.kill();
403-
await shell.waitForExit();
402+
shell.writeInputLine('exit');
403+
await shell.waitForAnyExit(); // closing the server may lead to an error being displayed
404404
});
405405

406406
const server = startTestServer('e2e-tls-valid-cli-valid-srv', {

0 commit comments

Comments
 (0)