MCPcopy Create free account
hub / github.com/denoland/std / next

Method next

testing/time.ts:713–717  ·  view source on GitHub ↗

* Advances time to when the next scheduled timer is due. * If there are no pending timers, time will not be changed. * * @example Usage * ```ts * import { FakeTime } from "@std/testing/time"; * import { assert, assertEquals } from "@std/assert"; * * const fakeTime = new FakeT

()

Source from the content-addressed store, hash-verified

711 * @returns `true` when there is a scheduled timer and `false` when there is not.
712 */
713 next(): boolean {
714 const next = nextDueNode();
715 if (next) this.now = next.due;
716 return !!next;
717 }
718
719 /**
720 * Runs all pending microtasks then advances time to when the next scheduled timer is due.

Callers 7

nextAsyncMethod · 0.95
runAllMethod · 0.95
time_test.tsFile · 0.45
setTimerFunction · 0.45
returnsNextFunction · 0.45
resolvesNextFunction · 0.45
titleCaseSegmentFunction · 0.45

Calls 1

nextDueNodeFunction · 0.85

Tested by

no test coverage detected