We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent d7c2b90 commit a8cbfb7Copy full SHA for a8cbfb7
index.d.ts
@@ -5,15 +5,15 @@ export interface Subscribable {
5
}): void;
6
}
7
8
-export type Constructor = (new (...args: any[]) => any);
+export type ErrorConstructor = new (...args: any[]) => Error;
9
10
/** Specify one or more expectations the thrown error must satisfy. */
11
export type ThrowsExpectation = {
12
/** The thrown error must have a code that equals the given string or number. */
13
code?: string | number;
14
15
/** The thrown error must be an instance of this constructor. */
16
- instanceOf?: Constructor;
+ instanceOf?: ErrorConstructor;
17
18
/** The thrown error must be strictly equal to this value. */
19
is?: Error;
0 commit comments