Skip to content

Commit bf57041

Browse files
committed
test(NODE-6858): handle MongoServerSelectionError
1 parent 69c8141 commit bf57041

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

src/error.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1551,9 +1551,9 @@ export function isResumableError(error?: Error, wireVersion?: number): boolean {
15511551
return true;
15521552
}
15531553

1554-
// if (error instanceof MongoServerSelectionError) {
1555-
// return true;
1556-
// }
1554+
if (error instanceof MongoServerSelectionError) {
1555+
return true;
1556+
}
15571557

15581558
if (wireVersion != null && wireVersion >= 9) {
15591559
// DRIVERS-1308: For 4.4 drivers running against 4.4 servers, drivers will add a special case to treat the CursorNotFound error code as resumable

test/integration/change-streams/change_stream.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1820,7 +1820,7 @@ describe('Change Streams', function () {
18201820
});
18211821
});
18221822

1823-
describe.only('ChangeStream resumability', function () {
1823+
describe('ChangeStream resumability', function () {
18241824
let client: MongoClient;
18251825
let collection: Collection;
18261826
let changeStream: ChangeStream;

0 commit comments

Comments
 (0)