electron@22.3.3, esbuild@0.17.11, typescript@5.0.2
This commit is contained in:
parent
27b7060d09
commit
28adb58c69
5 changed files with 198 additions and 180 deletions
|
@ -32,7 +32,9 @@ describe('clearTimeoutIfNecessary', () => {
|
|||
const fn = sinon.fake();
|
||||
const timeout = setTimeout(fn, 123);
|
||||
|
||||
clearTimeoutIfNecessary(timeout);
|
||||
clearTimeoutIfNecessary(
|
||||
timeout as unknown as ReturnType<typeof setTimeout>
|
||||
);
|
||||
|
||||
await clock.tickAsync(9999);
|
||||
sinon.assert.notCalled(fn);
|
||||
|
@ -43,7 +45,9 @@ describe('clearTimeoutIfNecessary', () => {
|
|||
const fn = sinon.fake();
|
||||
const interval = setInterval(fn, 123);
|
||||
|
||||
clearTimeoutIfNecessary(interval);
|
||||
clearTimeoutIfNecessary(
|
||||
interval as unknown as ReturnType<typeof setTimeout>
|
||||
);
|
||||
|
||||
await clock.tickAsync(9999);
|
||||
sinon.assert.notCalled(fn);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue