test: opravy Playwright testů
CI / Generate TypeScript types (push) Successful in 9s
CI / Generate TypeScript types (pull_request) Successful in 11s
CI / Server unit tests (push) Successful in 22s
CI / Build server (push) Successful in 29s
CI / Server unit tests (pull_request) Successful in 25s
CI / Build client (push) Successful in 34s
CI / Build server (pull_request) Successful in 30s
CI / Build client (pull_request) Successful in 32s
CI / Playwright E2E tests (push) Failing after 1m48s
CI / Build and push Docker image (push) Has been skipped
CI / Notify (push) Successful in 4s
CI / Playwright E2E tests (pull_request) Failing after 1m48s
CI / Build and push Docker image (pull_request) Has been skipped
CI / Notify (pull_request) Has been skipped
CI / Generate TypeScript types (push) Successful in 9s
CI / Generate TypeScript types (pull_request) Successful in 11s
CI / Server unit tests (push) Successful in 22s
CI / Build server (push) Successful in 29s
CI / Server unit tests (pull_request) Successful in 25s
CI / Build client (push) Successful in 34s
CI / Build server (pull_request) Successful in 30s
CI / Build client (pull_request) Successful in 32s
CI / Playwright E2E tests (push) Failing after 1m48s
CI / Build and push Docker image (push) Has been skipped
CI / Notify (push) Successful in 4s
CI / Playwright E2E tests (pull_request) Failing after 1m48s
CI / Build and push Docker image (pull_request) Has been skipped
CI / Notify (pull_request) Has been skipped
This commit is contained in:
@@ -30,6 +30,8 @@ test.describe.serial('pizza day životní cyklus', () => {
|
||||
const createBtn = page.locator('.pizza-section button', { hasText: 'Založit Pizza day' });
|
||||
await expect(createBtn).toBeVisible({ timeout: 10_000 });
|
||||
await createBtn.click();
|
||||
// Reload zajistí aktuální stav – aktualizace přichází přes WebSocket, který networkidle nečeká
|
||||
await page.reload();
|
||||
await page.waitForLoadState('networkidle');
|
||||
await expect(page.locator('.pizza-section')).toContainText('spravován uživatelem', { timeout: 5_000 });
|
||||
|
||||
|
||||
@@ -24,9 +24,10 @@ test('Nastavení ukládají číslo účtu a jméno do localStorage', async ({ p
|
||||
await expect(page.locator('.modal-title')).toContainText('Nastavení', { timeout: 5_000 });
|
||||
|
||||
// Změníme číslo účtu – pressSequentially zajistí spuštění React onChange na každý znak
|
||||
// Číslo 1000000005 je platné (kontrolní součet mod 11 = 0), jinak by validace zamítla uložení
|
||||
const accountInput = page.getByPlaceholder('123456-1234567890/1234');
|
||||
await accountInput.click({ clickCount: 3 });
|
||||
await accountInput.pressSequentially('1234567890/5500');
|
||||
await accountInput.pressSequentially('1000000005/5500');
|
||||
|
||||
// Změníme jméno
|
||||
const nameInput = page.getByPlaceholder('Jan Novák');
|
||||
@@ -40,7 +41,7 @@ test('Nastavení ukládají číslo účtu a jméno do localStorage', async ({ p
|
||||
// Ověříme v localStorage
|
||||
const bankAccount = await page.evaluate(() => localStorage.getItem('bank_account_number'));
|
||||
const holderName = await page.evaluate(() => localStorage.getItem('bank_account_holder_name'));
|
||||
expect(bankAccount).toBe('1234567890/5500');
|
||||
expect(bankAccount).toBe('1000000005/5500');
|
||||
expect(holderName).toBe('Nové Jméno');
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user