@@ -148,7 +148,7 @@ it('should call onChange', () => {
|
|||||||
const selectEl = screen.getByLabelText('My select');
|
const selectEl = screen.getByLabelText('My select');
|
||||||
expect(selectEl).toBeInTheDocument();
|
expect(selectEl).toBeInTheDocument();
|
||||||
|
|
||||||
await selectEvent.select(selectEl, 'Option 2');
|
await selectEvent.select(selectEl, 'Option 2', { container: document.body });
|
||||||
expect(onChange).toHaveBeenCalledWith({
|
expect(onChange).toHaveBeenCalledWith({
|
||||||
label: 'Option 2',
|
label: 'Option 2',
|
||||||
value: 2,
|
value: 2,
|
||||||
|
|||||||
Reference in New Issue
Block a user