MCPcopy Create free account
hub / github.com/nodejs/node / run

Function run

test/parallel/test-runner-mock-timers.js:712–720  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

710 const interval = 1000;
711 let time = 0;
712 async function run() {
713 const times = [];
714 for await (const _ of nodeTimersPromises.setInterval(interval)) { // eslint-disable-line no-unused-vars
715 time += interval;
716 times.push(time);
717 if (times.length === expectedIterations) break;
718 }
719 return times;
720 }
721
722 const r = run();
723 t.mock.timers.tick(interval);

Callers 1

Calls 1

pushMethod · 0.45

Tested by

no test coverage detected