Skip to content

Commit 4900134

Browse files
cleanup and fix lint
1 parent 5fa79e9 commit 4900134

File tree

2 files changed

+17
-7
lines changed

2 files changed

+17
-7
lines changed

test/integration/client-side-operations-timeout/client_side_operations_timeout.prose.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ import {
2121
promiseWithResolvers,
2222
squashError
2323
} from '../../mongodb';
24-
import { type FailPoint, makeMultiBatchWrite, waitUntilPoolsFilled } from '../../tools/utils';
24+
import { type FailPoint, makeMultiBatchWrite } from '../../tools/utils';
2525
import { filterForCommands } from '../shared';
2626

2727
// TODO(NODE-5824): Implement CSOT prose tests

test/integration/crud/explain.test.ts

Lines changed: 16 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -312,25 +312,35 @@ describe('CRUD API explain option', function () {
312312
}
313313

314314
beforeEach(async function () {
315-
const uri = this.configuration.url({ useMultipleMongoses: false });
316-
client = this.configuration.newClient(uri, { monitorCommands: true });
317-
client.on('commandStarted', filterForCommands('explain', commands));
318-
319315
await configureFailPoint(
320316
this.configuration,
321317
{
322318
configureFailPoint: 'failCommand',
323-
mode: { times: 1 },
319+
mode: 'alwaysOn',
324320
data: {
325321
failCommands: ['explain'],
326322
blockConnection: true,
327323
blockTimeMS: 1000
328324
}
329325
},
330-
uri
326+
this.configuration.url({ useMultipleMongoses: false })
331327
);
332328
});
333329

330+
afterEach(async function () {
331+
await clearFailPoint(
332+
this.configuration,
333+
this.configuration.url({ useMultipleMongoses: false })
334+
);
335+
});
336+
337+
beforeEach(async function () {
338+
const uri = this.configuration.url({ useMultipleMongoses: false });
339+
client = this.configuration.newClient(uri, { monitorCommands: true });
340+
client.on('commandStarted', filterForCommands('explain', commands));
341+
await client.connect();
342+
});
343+
334344
afterEach(async function () {
335345
await clearFailPoint(
336346
this.configuration,

0 commit comments

Comments
 (0)