MCPcopy
hub / github.com/vitest-dev/vitest / useRealTimers

Method useRealTimers

packages/vitest/src/integrations/mock/timers.ts:134–144  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

132 }
133
134 useRealTimers(): void {
135 if (this._fakingDate) {
136 resetDate()
137 this._fakingDate = null
138 }
139
140 if (this._fakingTime) {
141 this._clock.uninstall()
142 this._fakingTime = false
143 }
144 }
145
146 useFakeTimers(): void {
147 const fakeDate = this._fakingDate || Date.now()

Callers 15

disposeMethod · 0.95
useRealTimersFunction · 0.80
timers.test.tsFile · 0.80
date-mock.test.tsFile · 0.80
rpc.spec.tsFile · 0.80
wait.test.tsFile · 0.80
happy-dom.spec.tsFile · 0.80

Calls 1

resetDateFunction · 0.90

Tested by

no test coverage detected