chore: e2e-tests GitHub Action update

This commit is contained in:
pit
2023-09-27 10:11:32 +01:00
parent e82c12154b
commit f057666776
2 changed files with 3 additions and 0 deletions

View File

@ -19,6 +19,8 @@ jobs:
run: npm ci run: npm ci
- name: Copy env - name: Copy env
run: cp .env.example .env run: cp .env.example .env
- name: Build Documenso
run: npm run build
- name: Install Playwright Browsers - name: Install Playwright Browsers
run: npx playwright install --with-deps run: npx playwright install --with-deps
- name: Run Playwright tests - name: Run Playwright tests

View File

@ -29,6 +29,7 @@ setup('authenticate', async ({ page }: { page: Page }) => {
await page.getByLabel('Password', { exact: true }).fill(password); await page.getByLabel('Password', { exact: true }).fill(password);
await page.getByRole('button', { name: 'Sign In' }).click(); await page.getByRole('button', { name: 'Sign In' }).click();
await page.waitForURL('/documents');
await expect(page).toHaveURL('/documents'); await expect(page).toHaveURL('/documents');
await page.context().storageState({ path: STORAGE_STATE }); await page.context().storageState({ path: STORAGE_STATE });
}); });