From 7a2e82b8fb6f3b8913d07c6775213696f4b1092a Mon Sep 17 00:00:00 2001 From: XnpioChV Date: Thu, 11 Jul 2024 12:22:11 +0200 Subject: [PATCH] fix: LibraryAuthoringPage.test.tsx --- src/library-authoring/LibraryAuthoringPage.test.tsx | 4 ++-- webpack.dev-tutor.config.js | 0 2 files changed, 2 insertions(+), 2 deletions(-) create mode 100755 webpack.dev-tutor.config.js diff --git a/src/library-authoring/LibraryAuthoringPage.test.tsx b/src/library-authoring/LibraryAuthoringPage.test.tsx index 80d732d981..6b42e9902e 100644 --- a/src/library-authoring/LibraryAuthoringPage.test.tsx +++ b/src/library-authoring/LibraryAuthoringPage.test.tsx @@ -149,7 +149,7 @@ describe('', () => { axiosMock.onGet(getContentLibraryApiUrl(libraryData.id)).reply(200, libraryData); const { - getByRole, getByText, queryByText, getAllByText, + getByRole, getByText, queryByText, findByText, } = render(); // Ensure the search endpoint is called @@ -163,7 +163,7 @@ describe('', () => { expect(getByText('Recently Modified')).toBeInTheDocument(); expect(getByText('Collections (0)')).toBeInTheDocument(); expect(getByText('Components (6)')).toBeInTheDocument(); - expect(getAllByText('Test HTML Block')[0]).toBeInTheDocument(); + expect(await findByText('Test HTML Block')).toBeInTheDocument(); // Navigate to the components tab fireEvent.click(getByRole('tab', { name: 'Components' })); diff --git a/webpack.dev-tutor.config.js b/webpack.dev-tutor.config.js new file mode 100755 index 0000000000..e69de29bb2