Skip to content
Prev Previous commit
Next Next commit
Move mocked function into test
  • Loading branch information
opr committed Jan 11, 2022
commit 003c5ad5de1f178f15b3c39974574ffd4df72e3f
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,8 @@ import { render, fireEvent } from '@testing-library/react';
import { CustomSelectControl } from '@wordpress/components';

describe( 'CustomSelectControl', () => {
const onKeyDown = jest.fn();

it( 'Captures the keypress event and does not let it propagate', () => {
const onKeyDown = jest.fn();
const wrapper = (
<div
// This role="none" is required to prevent an eslint warning about accessibility.
Expand Down