File size: 378 Bytes
1e92f2d
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
import { warnCache } from '../../packages/react-instantsearch-hooks/src/lib/warn';
import { toWarnDev } from './matchers';

expect.extend({ toWarnDev });

// We hide console warnings to not pollute the test logs.
global.console.warn = jest.fn();

beforeEach(() => {
  // We reset the log's cache for our log assertions to be isolated in each test.
  warnCache.current = {};
});