1 |
|
2 |
|
3 |
|
4 |
|
5 | type DefaultConsole = Console;
|
6 | type ConsoleProps = keyof DefaultConsole;
|
7 |
|
8 | declare module 'jest-mock-console' {
|
9 | export default function MockConsole(): RestoreConsole;
|
10 | export default function MockConsole(mockArg: ConsoleProps): RestoreConsole;
|
11 | export default function MockConsole(mockArg: ConsoleProps[]): RestoreConsole;
|
12 | export default function MockConsole(mockArg: MockObj): RestoreConsole;
|
13 |
|
14 | type MockObj = {[key in ConsoleProps]?: DefaultConsole[key]};
|
15 | type RestoreConsole = () => void;
|
16 | } |
\ | No newline at end of file |