Skip to content

Commit 484519d

Browse files
committed
test(NODE-5484): fix unit test
1 parent 12d8aa7 commit 484519d

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

test/unit/error.test.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ describe('MongoErrors', () => {
9999
expect(err).to.be.an.instanceof(Error);
100100
expect(err.name).to.equal('MongoError');
101101
expect(err.message).to.equal(errorMessage);
102-
expect(err).to.have.property('cause', inputError);
102+
expect(err).to.not.have.property('cause');
103103
});
104104
});
105105

@@ -169,7 +169,7 @@ describe('MongoErrors', () => {
169169
context('when options.cause is not set', () => {
170170
it('attaches the cause property to the instance', () => {
171171
const error = new MongoMissingDependencyError('missing!', { cause: undefined });
172-
expect(error).to.not.have.property('cause');
172+
expect(error).to.have.property('cause').that.is.undefined;
173173
});
174174
});
175175
});

0 commit comments

Comments
 (0)