diff --git a/e2e/rook.spec.ts b/e2e/rook.spec.ts index bb6f15d..cdf26f6 100644 --- a/e2e/rook.spec.ts +++ b/e2e/rook.spec.ts @@ -42,8 +42,12 @@ test.describe('Rook plugin smoke tests', () => { test('navigation to storage classes view works', async ({ page }) => { await page.goto('/c/main/rook-ceph'); - const sidebar = page.getByRole('navigation', { name: 'Navigation' }); + + const rookBtn = sidebar.getByRole('button', { name: /rook/i }); + await rookBtn.click(); + await page.waitForLoadState('networkidle'); + const storageClassesLink = sidebar.getByRole('link', { name: /storage classes/i }); await expect(storageClassesLink).toBeVisible({ timeout: 10_000 }); await storageClassesLink.click(); @@ -56,8 +60,9 @@ test.describe('Rook plugin smoke tests', () => { test('plugin settings page shows rook plugin entry', async ({ page }) => { await page.goto('/settings/plugins'); await page.waitForLoadState('networkidle'); + await page.waitForSelector('[class*="PluginList"], [class*="plugins"], table, list', { timeout: 10_000 }).catch(() => {}); - const pluginEntry = page.locator('text=rook').first(); + const pluginEntry = page.locator('text=/rook/i').first(); await expect(pluginEntry).toBeVisible({ timeout: 30_000 }); }); });