diff --git a/frontend/src/components/common/copyable/copy-to-clipboard-button/copy-to-clipboard-button.test.tsx b/frontend/src/components/common/copyable/copy-to-clipboard-button/copy-to-clipboard-button.test.tsx index a314291e4..afd5080ea 100644 --- a/frontend/src/components/common/copyable/copy-to-clipboard-button/copy-to-clipboard-button.test.tsx +++ b/frontend/src/components/common/copyable/copy-to-clipboard-button/copy-to-clipboard-button.test.tsx @@ -39,7 +39,7 @@ describe('Copy to clipboard button', () => { const view = render(copyToClipboardButton) expect(view.container).toMatchSnapshot() const button = await screen.findByTitle('renderer.highlightCode.copyCode') - await act(() => { + await act(() => { button.click() }) const tooltip = await screen.findByRole('tooltip') diff --git a/frontend/src/components/common/motd-modal/motd-modal.test.tsx b/frontend/src/components/common/motd-modal/motd-modal.test.tsx index 49cf7ebf4..5eb11c364 100644 --- a/frontend/src/components/common/motd-modal/motd-modal.test.tsx +++ b/frontend/src/components/common/motd-modal/motd-modal.test.tsx @@ -60,7 +60,7 @@ describe('motd modal', () => { expect(view.container).toMatchSnapshot() const button = await screen.findByTestId('motd-dismiss') - await act(() => { + await act(() => { button.click() }) expect(view.container).toMatchSnapshot() diff --git a/frontend/src/components/common/note-loading-boundary/create-non-existing-note-hint.test.tsx b/frontend/src/components/common/note-loading-boundary/create-non-existing-note-hint.test.tsx index 8357d1505..815ad9248 100644 --- a/frontend/src/components/common/note-loading-boundary/create-non-existing-note-hint.test.tsx +++ b/frontend/src/components/common/note-loading-boundary/create-non-existing-note-hint.test.tsx @@ -77,7 +77,7 @@ describe('create non existing note hint', () => { const onNoteCreatedCallback = jest.fn() const view = render() const button = await screen.findByTestId('createNoteButton') - await act(() => { + await act(() => { button.click() }) await waitFor(async () => { @@ -92,7 +92,7 @@ describe('create non existing note hint', () => { const onNoteCreatedCallback = jest.fn() const view = render() const button = await screen.findByTestId('createNoteButton') - await act(() => { + await act(() => { button.click() }) await waitFor(async () => { @@ -107,7 +107,7 @@ describe('create non existing note hint', () => { const onNoteCreatedCallback = jest.fn() const view = render() const button = await screen.findByTestId('createNoteButton') - await act(() => { + await act(() => { button.click() }) await waitFor(async () => { diff --git a/frontend/src/components/editor-page/document-bar/aliases/aliases-add-form.test.tsx b/frontend/src/components/editor-page/document-bar/aliases/aliases-add-form.test.tsx index 480023e74..8511d61d6 100644 --- a/frontend/src/components/editor-page/document-bar/aliases/aliases-add-form.test.tsx +++ b/frontend/src/components/editor-page/document-bar/aliases/aliases-add-form.test.tsx @@ -46,7 +46,7 @@ describe('AliasesAddForm', () => { const input = await screen.findByTestId('addAliasInput') await testEvent.type(input, 'abc') expect(button).toBeEnabled() - await act(() => { + await act(() => { button.click() }) expect(AliasModule.addAlias).toBeCalledWith('mock-note', 'abc') diff --git a/frontend/src/components/editor-page/document-bar/aliases/aliases-list-entry.test.tsx b/frontend/src/components/editor-page/document-bar/aliases/aliases-list-entry.test.tsx index e17558a66..81f391dd0 100644 --- a/frontend/src/components/editor-page/document-bar/aliases/aliases-list-entry.test.tsx +++ b/frontend/src/components/editor-page/document-bar/aliases/aliases-list-entry.test.tsx @@ -46,7 +46,7 @@ describe('AliasesListEntry', () => { const view = render() expect(view.container).toMatchSnapshot() const button = await screen.findByTestId('aliasButtonRemove') - await act(() => { + await act(() => { button.click() }) expect(AliasModule.deleteAlias).toBeCalledWith(testAlias.name) @@ -63,14 +63,14 @@ describe('AliasesListEntry', () => { const view = render() expect(view.container).toMatchSnapshot() const buttonRemove = await screen.findByTestId('aliasButtonRemove') - await act(() => { + await act(() => { buttonRemove.click() }) expect(AliasModule.deleteAlias).toBeCalledWith(testAlias.name) await deletePromise expect(NoteDetailsReduxModule.updateMetadata).toBeCalled() const buttonMakePrimary = await screen.findByTestId('aliasButtonMakePrimary') - await act(() => { + await act(() => { buttonMakePrimary.click() }) expect(AliasModule.markAliasAsPrimary).toBeCalledWith(testAlias.name) diff --git a/frontend/src/components/layout/settings-dialog/utils/on-off-button-group.test.tsx b/frontend/src/components/layout/settings-dialog/utils/on-off-button-group.test.tsx index ae9d7c2e9..22dfc7678 100644 --- a/frontend/src/components/layout/settings-dialog/utils/on-off-button-group.test.tsx +++ b/frontend/src/components/layout/settings-dialog/utils/on-off-button-group.test.tsx @@ -17,7 +17,7 @@ describe('Settings On-Off Button Group', () => { const view = render() expect(view.container).toMatchSnapshot() const onButton = await screen.findByTestId('onOffButtonGroupOn') - await act(() => { + await act(() => { onButton.click() }) expect(value).toBeTruthy() @@ -25,7 +25,7 @@ describe('Settings On-Off Button Group', () => { view.rerender() expect(view.container).toMatchSnapshot() const offButton = await screen.findByTestId('onOffButtonGroupOff') - await act(() => { + await act(() => { offButton.click() }) expect(value).toBeFalsy()