fix(e2e): Extra 3s Wait in Overview-Tests fuer API-Fetch-Timing
Die letzten 3 Schwingarm-Failures kommen weil die Overview-Seite 2 parallele API-Fetches (project + risk-summary) braucht bevor der Content rendert. goTo wartet auf h1, aber die h2-Sektionen (Risikozusammenfassung, Schnellzugriff) rendern erst danach. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -129,8 +129,10 @@ for (const project of PROJECTS) {
|
||||
test.setTimeout(60_000)
|
||||
|
||||
// ------ Overview ------
|
||||
// Overview tests need extra wait — React hydration + 2 parallel API fetches
|
||||
test('overview page loads', async ({ page }) => {
|
||||
await goTo(page, `/sdk/iace/${project.id}`)
|
||||
await page.waitForTimeout(3000) // Extra wait for overview API fetches
|
||||
// React hydration error #418 is a known issue (SSR renders "Kein Projekt" before API fetch)
|
||||
// so we only check that the project name appears eventually, not assertNoAppError
|
||||
await expect(page.locator(`text=${project.name}`).first()).toBeVisible({ timeout: 20000 })
|
||||
@@ -138,7 +140,7 @@ for (const project of PROJECTS) {
|
||||
|
||||
test('overview — status workflow visible', async ({ page }) => {
|
||||
await goTo(page, `/sdk/iace/${project.id}`)
|
||||
// Status workflow or risk summary or process steps should be visible
|
||||
await page.waitForTimeout(3000)
|
||||
await expect(
|
||||
page.locator('text=Projektstatus').or(page.locator('text=Risikozusammenfassung')).or(page.locator('text=CE-Prozessschritte'))
|
||||
).toBeVisible({ timeout: 20000 })
|
||||
@@ -146,6 +148,7 @@ for (const project of PROJECTS) {
|
||||
|
||||
test('overview — risk summary or process info', async ({ page }) => {
|
||||
await goTo(page, `/sdk/iace/${project.id}`)
|
||||
await page.waitForTimeout(3000)
|
||||
await expect(
|
||||
page.locator('text=Risikozusammenfassung').or(page.locator('text=Maschineninformationen')).or(page.locator('text=CE-Prozessschritte'))
|
||||
).toBeVisible({ timeout: 20000 })
|
||||
@@ -160,6 +163,7 @@ for (const project of PROJECTS) {
|
||||
|
||||
test('overview — completeness gates section', async ({ page }) => {
|
||||
await goTo(page, `/sdk/iace/${project.id}`)
|
||||
await page.waitForTimeout(3000)
|
||||
// Completeness may be called "Completeness Gates" or shown as progress percentage
|
||||
await expect(
|
||||
page.locator('text=Completeness Gates').or(page.locator('text=Projektfortschritt')).or(page.locator('text=CE-Prozessschritte'))
|
||||
@@ -168,6 +172,7 @@ for (const project of PROJECTS) {
|
||||
|
||||
test('overview — quick actions or nav present', async ({ page }) => {
|
||||
await goTo(page, `/sdk/iace/${project.id}`)
|
||||
await page.waitForTimeout(3000)
|
||||
// Quick actions or IACE sidebar navigation should be visible
|
||||
await expect(
|
||||
page.locator('text=Schnellzugriff').or(page.locator('text=Komponenten').first())
|
||||
|
||||
Reference in New Issue
Block a user