Skip to content

Commit 0679947

Browse files
committed
test: unit test fixes
1 parent 8e248d5 commit 0679947

File tree

2 files changed

+0
-38
lines changed

2 files changed

+0
-38
lines changed

test/unit/connection_string.test.ts

Lines changed: 0 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -794,42 +794,6 @@ describe('Connection String', function () {
794794
expect(() => new MongoClient('mango+srv://localhost:23')).to.throw(/Invalid scheme/i);
795795
});
796796

797-
describe('when deprecated options are used', () => {
798-
it('useNewUrlParser emits a warning', async () => {
799-
let willBeWarning = once(process, 'warning');
800-
parseOptions('mongodb://host?useNewUrlParser=true');
801-
let [warning] = await willBeWarning;
802-
expect(warning)
803-
.to.have.property('message')
804-
.that.matches(/useNewUrlParser has no effect/);
805-
806-
willBeWarning = once(process, 'warning');
807-
//@ts-expect-error: using unsupported option on purpose
808-
parseOptions('mongodb://host', { useNewUrlParser: true });
809-
[warning] = await willBeWarning;
810-
expect(warning)
811-
.to.have.property('message')
812-
.that.matches(/useNewUrlParser has no effect/);
813-
});
814-
815-
it('useUnifiedTopology emits a warning', async () => {
816-
let willBeWarning = once(process, 'warning');
817-
parseOptions('mongodb://host?useUnifiedTopology=true');
818-
let [warning] = await willBeWarning;
819-
expect(warning)
820-
.to.have.property('message')
821-
.that.matches(/useUnifiedTopology has no effect/);
822-
823-
willBeWarning = once(process, 'warning');
824-
//@ts-expect-error: using unsupported option on purpose
825-
parseOptions('mongodb://host', { useUnifiedTopology: true });
826-
[warning] = await willBeWarning;
827-
expect(warning)
828-
.to.have.property('message')
829-
.that.matches(/useUnifiedTopology has no effect/);
830-
});
831-
});
832-
833797
describe('when mongodbLogPath is in options', function () {
834798
let stderrStub;
835799
let stdoutStub;

test/unit/mongo_client.test.ts

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -273,8 +273,6 @@ describe('MongoClient', function () {
273273
expect(options.readPreference.mode).to.equal('nearest');
274274
expect(options.readPreference.tags).to.be.an('array').that.includes(tag);
275275
expect(options.readPreference.maxStalenessSeconds).to.equal(20);
276-
// maxStalenessSeconds sets the minWireVersion
277-
expect(options.readPreference.minWireVersion).to.be.at.least(5);
278276
});
279277

280278
it('should throw when given a readpreference options with an unsupported type', () => {

0 commit comments

Comments
 (0)