diff --git a/tests/websockets/connection.spec.ts b/tests/websockets/connection.spec.ts index 9ea0572b2..4f9edfd28 100644 --- a/tests/websockets/connection.spec.ts +++ b/tests/websockets/connection.spec.ts @@ -2,10 +2,9 @@ import { expect, test } from '../../playwright'; import { buildCommonLocators } from './lib/locators'; const MAX_CONNECTION_TIME = 3000; -const BRU_FILE_NAME = /^ws-test-request$/ +const BRU_FILE_NAME = /^ws-test-request$/; test.describe.serial('websockets', () => { - test.setTimeout(2 * 10 * 1000); test('websocket requests are visible', async ({ pageWithUserData: page, restartApp }) => { await page.locator('#sidebar-collection-name').click(); @@ -19,7 +18,7 @@ test.describe.serial('websockets', () => { await locators.connectionControls.connect().click(); await expect(locators.connectionControls.disconnect()).toBeAttached({ - timeout: MAX_CONNECTION_TIME + timeout: MAX_CONNECTION_TIME, }); }); @@ -61,7 +60,7 @@ test.describe.serial('websockets', () => { await locators.runner().click(); const messages = await locators.messages(); - + expect(await messages[1].locator('.text-ellipsis').innerText()).toMatch('{ "foo": "bar" }'); expect(await messages[2].locator('.text-ellipsis').innerText()).toMatch('{ "data": { "foo": "bar" } }'); diff --git a/tests/websockets/headers.spec.ts b/tests/websockets/headers.spec.ts index 81f6e379d..9a8459fe1 100644 --- a/tests/websockets/headers.spec.ts +++ b/tests/websockets/headers.spec.ts @@ -4,15 +4,14 @@ import { buildCommonLocators } from './lib/locators'; const BRU_FILE_NAME = /^ws-test-request-with-headers$/; test.describe.serial('headers', () => { - test.setTimeout(2 * 10 * 1000); test('headers are returned if passed', async ({ pageWithUserData: page, restartApp }) => { const locators = buildCommonLocators(page); - + await page.locator('#sidebar-collection-name').click(); await page.getByTitle(BRU_FILE_NAME).click(); await locators.runner().click(); - + const messages = await locators.messages(); - expect(await messages[2].locator('.text-ellipsis').innerText()).toMatch(/\"(authorization)\"\:\s+\"Dummy\"/) + expect(await messages[2].locator('.text-ellipsis').innerText()).toMatch(/\"(authorization)\"\:\s+\"Dummy\"/); }); });