diff --git a/test/servers/helpers/ImportServersBtn.test.tsx b/test/servers/helpers/ImportServersBtn.test.tsx index 2d7d7194..be37559c 100644 --- a/test/servers/helpers/ImportServersBtn.test.tsx +++ b/test/servers/helpers/ImportServersBtn.test.tsx @@ -21,9 +21,9 @@ describe('', () => { it('shows tooltip on button hover', async () => { const { user, ...screen } = await setUp(); - await expect.element(screen.getByText('You can create servers by importing a CSV file')).not.toBeInTheDocument(); + await expect.element(screen.getByText(/You can create servers by importing a CSV file/)).not.toBeInTheDocument(); await user.hover(screen.getByRole('button')); - await expect.element(screen.getByText('You can create servers by importing a CSV file')).toBeInTheDocument(); + await expect.element(screen.getByText(/You can create servers by importing a CSV file/)).toBeInTheDocument(); }); it.each([ diff --git a/test/servers/helpers/ServerError.test.tsx b/test/servers/helpers/ServerError.test.tsx index 706b1d85..7843fc32 100644 --- a/test/servers/helpers/ServerError.test.tsx +++ b/test/servers/helpers/ServerError.test.tsx @@ -28,7 +28,7 @@ describe('', () => { found: ['Could not find this Shlink server.'], notFound: [ 'Oops! Could not connect to this Shlink server.', - 'Make sure you have internet connection, and the server is properly configured and on-line.', + /Make sure you have internet connection, and the server is properly configured and on-line/, /^Alternatively, if you think you may have misconfigured this server/, ], }, @@ -38,7 +38,7 @@ describe('', () => { { found: [ 'Oops! Could not connect to this Shlink server.', - 'Make sure you have internet connection, and the server is properly configured and on-line.', + /Make sure you have internet connection, and the server is properly configured and on-line/, /^Alternatively, if you think you may have misconfigured this server/, ], notFound: ['Could not find this Shlink server.'],