-
Notifications
You must be signed in to change notification settings - Fork 539
Open
Description
I am using following versions of deps for my project
- bcrypt: 6.0.0
- Node: 20.19.1
- npm: 10.8.2
I am trying to run a unit test as follows
it('returns true if password and hash match', async () => {
const password = uuid();
const passwordHash = await hash(password);
expect(await compare(password, passwordHash)).to.be.equal(true);
});
The test fails with following error
Error: Timeout of 2000ms exceeded. For async tests and hooks, ensure "done()" is called; if returning a Promise, ensure it resolves. (/<path-to-repo>/test/new-unit/common/bcrypt.test.js)
at listOnTimeout (node:internal/timers:581:17)
at process.processTimers (node:internal/timers:519:7)
What I found is that the node_modules/bcrypt does not contains the compatible version of bcrypt.node for MacOS 15.6.1. Unfortunately I do not have MacOS 16 version so I was unable to test this.
Note: When I tried updating timeout to 5s, the test runs successully
Can someone help?
Metadata
Metadata
Assignees
Labels
No labels