Files
bruno/tests/websockets/query.spec.ts
Pooja a22eb43a27 fix(websocket): add API Key query params support and OAuth2 inheritan… (#6271)
* fix(websocket): add API Key query params support and OAuth2 inheritance warning

* add: playwright test
2026-01-21 18:56:46 +05:30

21 lines
767 B
TypeScript

import { test, expect } from '../../playwright';
import { buildWebsocketCommonLocators } from '../utils/page/locators';
const BRU_REQ_NAME = /^ws-test-request-with-query$/;
test.describe.serial('query params', () => {
test('query params are returned if passed', async ({ pageWithUserData: page }) => {
const locators = buildWebsocketCommonLocators(page);
// Open the most recent collection
await page.locator('#sidebar-collection-name').click();
// Click on the required request
await page.getByTitle(BRU_REQ_NAME).click();
await locators.runner().click();
// Check if the message has the query params
await expect(locators.messages().nth(2).locator('.text-ellipsis')).toHaveText(/\"(testParam)\"\:\s+\"testValue\"/);
});
});