fix prerelease tests

This commit is contained in:
jackkav 2023-08-04 22:30:00 +02:00
parent c31f0a17f6
commit a8e436ea1d
3 changed files with 4 additions and 4 deletions

View File

@ -30,7 +30,6 @@ test.describe('Debug-Sidebar', async () => {
await page.getByRole('button', { name: 'example grpc' }).click();
await page.locator('[data-testid="Dropdown-example-grpc"]').click();
await page.getByRole('menuitem', { name: 'Settings' }).click();
await page.getByRole('tab', { name: 'Preview' }).click();
// Close settings modal
await page.locator('.app').press('Escape');
});
@ -61,8 +60,8 @@ test.describe('Debug-Sidebar', async () => {
});
test('Open properties of the collection', async ({ page }) => {
await page.getByRole('button', { name: 'simple' }).click();
await page.getByRole('menuitem', { name: 'Collection Settings' }).click();
await page.getByTestId('workspace-dropdown').locator('button').click();
await page.getByRole('menuitem', { name: 'Settings' }).click();
await page.getByText('Collection Settings').click();
});

View File

@ -26,7 +26,7 @@ test.describe('Plugins', async () => {
await expect(page.locator('.app')).toContainText('This is a sample server Petstore server');
// Open declarative config
await page.getByRole('button', { name: 'New Document' }).click();
await page.getByTestId('workspace-dropdown').locator('button').click();
await page.getByRole('menuitem', { name: 'Declarative Config (Legacy)' }).click();
// Check for declarative config contents
await page.getByText('_format_version').click();

View File

@ -106,6 +106,7 @@ export const WorkspaceDropdown: FC = () => {
return (
<>
<Dropdown
dataTestId='workspace-dropdown'
aria-label="Workspace Dropdown"
ref={dropdownRef}
closeOnSelect={false}