This commit is contained in:
parent
4bcf505e19
commit
a14d9750b3
|
@ -34,6 +34,10 @@ The recommended approach is to use `setFixedTime` to set the time to a specific
|
|||
- `Event.timeStamp`
|
||||
:::
|
||||
|
||||
:::warning
|
||||
If you call `install` at any point in your test, the call _MUST_ occur before any other clock related calls (see note above for list). Calling these methods out of order will result in undefined behavior. For example, you cannot call `setInterval`, followed by `install`, then `clearInterval`, as `install` overrides the native definition of the clock functions.
|
||||
:::
|
||||
|
||||
## Test with predefined time
|
||||
|
||||
Often you only need to fake `Date.now` while keeping the timers going.
|
||||
|
|
Loading…
Reference in New Issue