File tree Expand file tree Collapse file tree 1 file changed +2
-15
lines changed
Expand file tree Collapse file tree 1 file changed +2
-15
lines changed Original file line number Diff line number Diff line change 1- import { jest , expect } from '@jest/globals' ;
1+ import { expect } from '@jest/globals' ;
22import '@testing-library/jest-dom' ;
33import { TestingLibraryMatchers } from '@testing-library/jest-dom/types/matchers-standalone' ;
44
55declare module '@jest/expect' {
6+ // eslint-disable-next-line @typescript-eslint/no-empty-object-type
67 export interface Matchers < R >
78 extends TestingLibraryMatchers < typeof expect . stringContaining , R > { }
89}
9-
10- Object . defineProperty ( window , 'matchMedia' , {
11- writable : true ,
12- value : jest . fn ( ) . mockImplementation ( ( query ) => ( {
13- matches : false ,
14- media : query ,
15- onchange : null ,
16- addListener : jest . fn ( ) , // deprecated
17- removeListener : jest . fn ( ) , // deprecated
18- addEventListener : jest . fn ( ) ,
19- removeEventListener : jest . fn ( ) ,
20- dispatchEvent : jest . fn ( ) ,
21- } ) ) ,
22- } ) ;
You can’t perform that action at this time.
0 commit comments