Skip to content

Commit cd09d43

Browse files
ci: skip flaky tests in retryable reads and sdam suites (#4466)
1 parent 86d4ca1 commit cd09d43

File tree

2 files changed

+40
-31
lines changed

2 files changed

+40
-31
lines changed

test/integration/retryable-reads/retryable_reads.spec.test.ts

+6
Original file line numberDiff line numberDiff line change
@@ -12,12 +12,18 @@ const UNIMPLEMENTED_APIS = [
1212
'listDatabaseObjects'
1313
];
1414

15+
const skippedTests = ['collection.listIndexes succeeds after retryable handshake network error'];
16+
1517
describe('Retryable Reads (unified)', function () {
1618
runUnifiedSuite(loadSpecTests(path.join('retryable-reads', 'unified')), ({ description }) => {
1719
for (const apiName of UNIMPLEMENTED_APIS) {
1820
if (description.toLowerCase().includes(apiName.toLowerCase())) {
1921
return `The Node.js Driver does not support ${apiName}`;
2022
}
23+
24+
if (skippedTests.includes(description)) {
25+
return `TODO(NODE-6832): fix flaky retryable reads tests`;
26+
}
2127
}
2228
return false;
2329
});

test/integration/server-discovery-and-monitoring/server_discovery_and_monitoring.prose.test.ts

+34-31
Original file line numberDiff line numberDiff line change
@@ -146,37 +146,40 @@ describe('Server Discovery and Monitoring Prose Tests', function () {
146146
await client.close();
147147
});
148148

149-
it('ensure monitors properly create and unpause connection pools when they discover servers', {
150-
metadata: { requires: { mongodb: '>=4.2.9', topology: '!load-balanced' } },
151-
test: async function () {
152-
await client.connect();
153-
expect(events.shift()).to.equal(SERVER_HEARTBEAT_SUCCEEDED);
154-
expect(events.shift()).to.equal(CONNECTION_POOL_READY);
155-
156-
expect(events).to.be.empty;
157-
158-
const heartBeatFailedEvent = once(client, SERVER_HEARTBEAT_FAILED);
159-
await client.db('admin').command({
160-
configureFailPoint: 'failCommand',
161-
mode: { times: 2 },
162-
data: {
163-
failCommands: ['hello'],
164-
errorCode: 1234,
165-
appName: 'SDAMPoolManagementTest'
166-
}
167-
});
168-
await heartBeatFailedEvent;
169-
expect(events.shift()).to.equal(SERVER_HEARTBEAT_FAILED);
170-
expect(events.shift()).to.equal(CONNECTION_POOL_CLEARED);
171-
172-
expect(events).to.be.empty;
173-
174-
await once(client, SERVER_HEARTBEAT_SUCCEEDED);
175-
expect(events.shift()).to.equal(SERVER_HEARTBEAT_SUCCEEDED);
176-
expect(events.shift()).to.equal(CONNECTION_POOL_READY);
177-
178-
expect(events).to.be.empty;
149+
it.skip(
150+
'ensure monitors properly create and unpause connection pools when they discover servers',
151+
{
152+
metadata: { requires: { mongodb: '>=4.2.9', topology: '!load-balanced' } },
153+
test: async function () {
154+
await client.connect();
155+
expect(events.shift()).to.equal(SERVER_HEARTBEAT_SUCCEEDED);
156+
expect(events.shift()).to.equal(CONNECTION_POOL_READY);
157+
158+
expect(events).to.be.empty;
159+
160+
const heartBeatFailedEvent = once(client, SERVER_HEARTBEAT_FAILED);
161+
await client.db('admin').command({
162+
configureFailPoint: 'failCommand',
163+
mode: { times: 2 },
164+
data: {
165+
failCommands: ['hello'],
166+
errorCode: 1234,
167+
appName: 'SDAMPoolManagementTest'
168+
}
169+
});
170+
await heartBeatFailedEvent;
171+
expect(events.shift()).to.equal(SERVER_HEARTBEAT_FAILED);
172+
expect(events.shift()).to.equal(CONNECTION_POOL_CLEARED);
173+
174+
expect(events).to.be.empty;
175+
176+
await once(client, SERVER_HEARTBEAT_SUCCEEDED);
177+
expect(events.shift()).to.equal(SERVER_HEARTBEAT_SUCCEEDED);
178+
expect(events.shift()).to.equal(CONNECTION_POOL_READY);
179+
180+
expect(events).to.be.empty;
181+
}
179182
}
180-
});
183+
).skipReason = 'TODO(NODE-5206): fix flaky test';
181184
});
182185
});

0 commit comments

Comments
 (0)