Replace fixed waits with waitForAngular in UI tests
The 3s waitForTimeout after page.goto wasn't enough for Angular to bootstrap and render content. Replace with waitForAngular() helper that waits for actual DOM elements (nav, headings) up to 15s, with 5s fallback. 32 calls updated across 10 test files. Also adds waitForAngular to helpers.ts export. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -18,6 +18,7 @@ import {
|
||||
createIntegrationViaApi,
|
||||
cleanupIntegrations,
|
||||
snap,
|
||||
waitForAngular,
|
||||
} from './helpers';
|
||||
|
||||
const BASE = process.env['PLAYWRIGHT_BASE_URL'] || 'https://stella-ops.local';
|
||||
@@ -119,7 +120,7 @@ test.describe('GitLab Integration — UI Verification', () => {
|
||||
waitUntil: 'domcontentloaded',
|
||||
timeout: 45_000,
|
||||
});
|
||||
await page.waitForTimeout(3_000);
|
||||
await waitForAngular(page);
|
||||
|
||||
const pageContent = await page.textContent('body');
|
||||
expect(pageContent).toContain('GitLab');
|
||||
|
||||
Reference in New Issue
Block a user