Skip to content

Commit eb1a16d

Browse files
committed
move the version check
1 parent 06b6ce5 commit eb1a16d

1 file changed

Lines changed: 9 additions & 4 deletions

File tree

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,16 @@
11
import * as path from 'path';
2+
import { gte } from 'semver';
23

34
import { loadSpecTests } from '../../spec';
45
import { runUnifiedSuite } from '../../tools/unified-spec-runner/runner';
56

6-
// TODO: NODE-7559 - remove the mongodb version requirement once the spec tests are updated to be compatible with MongoDB 9.0
7+
// TODO: NODE-7559 - remove once spec tests are compatible with MongoDB 9.0
78
describe('Change Streams Spec - Unified', function () {
8-
it('should run, unless it should not', { requires: { mongodb: '<9.0' } }, function () {
9-
runUnifiedSuite(loadSpecTests(path.join('change-streams', 'unified')));
10-
});
9+
runUnifiedSuite(
10+
loadSpecTests(path.join('change-streams', 'unified')),
11+
(_test, ctx) =>
12+
gte(ctx.version, '9.0.0')
13+
? 'TODO(NODE-7559): change stream spec tests not yet compatible with MongoDB >= 9.0'
14+
: false
15+
);
1116
});

0 commit comments

Comments
 (0)