Skip to content

Commit

Permalink
feat(): globalDurationTimer test fix,
Browse files Browse the repository at this point in the history
  • Loading branch information
Eugene Orlovsky committed Sep 12, 2024
1 parent 3a1b779 commit 402cf2d
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/utils/globalDurationTimer.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@ import { GlobalDurationTimer } from './globalDurationTimer';

describe('GlobalDurationTimer', () => {
function timeout(ms) {
const timer = setTimeout(() => {}, ms);
timer.unref(); // Ensures this timeout won't block the event loop from exiting
return new Promise((resolve) => setTimeout(resolve, ms));
}

Expand Down

0 comments on commit 402cf2d

Please sign in to comment.