Skip to content

Commit 09a3e13

Browse files
authored
🤖 Merge PR DefinitelyTyped#74827 [sinon] Fix @sinonjs/fake-timers config import by @alecgibson
1 parent 460dd9f commit 09a3e13

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

‎types/sinon/index.d.ts‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1182,7 +1182,7 @@ declare namespace Sinon {
11821182
* If set to true, the sandbox will have a clock property.
11831183
* You can optionally pass in a configuration object that follows the specification for fake timers, such as { toFake: ["setTimeout", "setInterval"] }.
11841184
*/
1185-
useFakeTimers: boolean | Partial<FakeTimers.FakeTimerInstallOpts>;
1185+
useFakeTimers: boolean | Partial<Parameters<typeof FakeTimers['install']>[0]>;
11861186
/**
11871187
* The assert options can help limit the amount of output produced by assert.fail
11881188
*/
@@ -1332,7 +1332,7 @@ declare namespace Sinon {
13321332
* * Important note: when faking `nextTick`, normal calls to `process.nextTick()` will not execute automatically as they would during normal event-loop phases. You would have to call either `clock.next()`, `clock.tick()`, `clock.runAll()` or `clock.runToLast()` manually (see example below). You can easily work around this using the `config.toFake` option. Please refer to the [`fake-timers`](https://github.com/sinonjs/fake-timers) documentation for more information.
13331333
* @param config
13341334
*/
1335-
useFakeTimers(config?: number | Date | Partial<FakeTimers.FakeTimerInstallOpts>): SinonFakeTimers;
1335+
useFakeTimers(config?: number | Date | Partial<Parameters<typeof FakeTimers['install']>[0]>): SinonFakeTimers;
13361336
/**
13371337
* Restores all fakes created through sandbox.
13381338
*/

0 commit comments

Comments
 (0)