Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
Clear the useViewportMatch mock after each test
  • Loading branch information
ramonjd committed Sep 4, 2023
commit 865aecb658558a5bd43454d677ba621f422d304e
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,9 @@ jest.mock( '@wordpress/compose/src/hooks/use-viewport-match', () => jest.fn() );

describe( 'EditPostPreferencesModal', () => {
describe( 'should match snapshot when the modal is active', () => {
afterEach( () => {
useViewportMatch.mockClear();
} );
it( 'large viewports', async () => {
useSelect.mockImplementation( () => [ true, true, false ] );
useViewportMatch.mockImplementation( () => true );
Expand Down