diff --git a/.github/workflows/docker.yml b/.github/workflows/docker.yml index c87a92f..402e1f5 100644 --- a/.github/workflows/docker.yml +++ b/.github/workflows/docker.yml @@ -170,7 +170,9 @@ jobs: if: always() with: name: playwright-report - path: ./frontend/playwright-report/ + path: | + ./frontend/playwright-report/ + ./frontend/screenshots/ retention-days: 30 release: diff --git a/frontend/integration_tests/basic.spec.ts b/frontend/integration_tests/basic.spec.ts index 33b8cdf..ce6137a 100644 --- a/frontend/integration_tests/basic.spec.ts +++ b/frontend/integration_tests/basic.spec.ts @@ -17,7 +17,7 @@ test('test good flow', async ({ page }) => { .click() await page.getByRole('button', { name: 'Change theme', exact: true }).click() await page.getByRole('button', { name: 'Orange' }).click() - const iframe = await page.frameLocator('#version-0') + let iframe = await page.frameLocator('#version-0') await expect(iframe.locator('h1')).toHaveText('Hello, world!') await expect(iframe.locator('img')).toHaveAttribute( 'src', @@ -27,4 +27,25 @@ test('test good flow', async ({ page }) => { await annotator?.screenshot({ path: './screenshots/annotator-screenshot.png' }) + await page.getByRole('button', { name: 'Edit HTML', exact: true }).click() + let monacoEditor = page.locator('.monaco-editor').nth(0) + await monacoEditor.click({ + position: { + x: 300, + y: 300 + } + }) + await monacoEditor.click({ + position: { + x: 300, + y: 300 + } + }) + await page.keyboard.type( + '