Skip to content

Commit

Permalink
test: fix mapper flow tests, first open page, then click card
Browse files Browse the repository at this point in the history
  • Loading branch information
spwoodcock committed Nov 27, 2024
1 parent 71cec9c commit defa9b2
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 7 deletions.
8 changes: 1 addition & 7 deletions src/frontend/e2e/02-mapper-flow.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -104,12 +104,9 @@ test.describe('mapper flow', () => {
// (playwright.config.ts is configured to run all browsers by default)
test.skip(browserName !== 'chromium', 'Test only for chromium!');

// 0. Temp Login
await tempLogin(page);
await openTestProject(page);

// 1. Click on task area on map
// click on task & assert task popup visibility
await openTestProject(page);
await page.locator('canvas').click({
position: {
x: 388,
Expand Down Expand Up @@ -173,10 +170,7 @@ test.describe('mapper flow', () => {
// (playwright.config.ts is configured to run all browsers by default)
test.skip(browserName !== 'chromium', 'Test only for chromium!');

// 0. Temp Login
await tempLogin(page);
await openTestProject(page);

await page.locator('canvas').click({
position: {
x: 475,
Expand Down
1 change: 1 addition & 0 deletions src/frontend/e2e/helpers.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import { Page } from '@playwright/test';

export async function openTestProject(page: Page) {
await page.goto('/');
// open project card with regex text 'Project Create Playwright xxx'
await page
.getByText(/^Project Create Playwright/)
Expand Down

0 comments on commit defa9b2

Please sign in to comment.