forked from Ruderverein-Donau-Linz/rowt
		
	Reviewed-on: Ruderverein-Donau-Linz/rowt#697
This commit is contained in:
		| @@ -102,6 +102,28 @@ test("Cox can start and finish trip", async ({ page }, testInfo) => { | ||||
|   await expect(page.locator('body')).toContainText('(cox2)'); | ||||
|   await expect(page.locator('body')).toContainText('Ottensheim (25 km)'); | ||||
|   await expect(page.locator('body')).toContainText('Ruderer: cox2, rower2'); | ||||
|  | ||||
|  | ||||
|   //Ausloggen... | ||||
|   await page.getByRole('banner').getByRole('link', { name: 'Logbuch' }).click(); | ||||
|   await page.getByRole('link', { name: 'Ausloggen' }).click(); | ||||
|   // Login as admin | ||||
|   await page.getByPlaceholder("Name").click(); | ||||
|   await page.getByPlaceholder("Name").fill("main"); | ||||
|   await page.getByPlaceholder("Name").press("Tab"); | ||||
|   await page.getByPlaceholder("Passwort").fill("admin"); | ||||
|   await page.getByPlaceholder("Passwort").press("Enter"); | ||||
|  | ||||
|   await page.goto("/log/show"); | ||||
|   await page.getByText('(cox2)').click(); | ||||
|   page.once("dialog", (dialog) => { | ||||
|     dialog.accept().catch(() => {}); | ||||
|   }); | ||||
|   await page.getByRole('link', { name: 'Löschen' }).click(); | ||||
|  | ||||
|   //Ausloggen... | ||||
|   await page.getByRole('banner').getByRole('link', { name: 'Logbuch' }).click(); | ||||
|   await page.getByRole('link', { name: 'Ausloggen' }).click(); | ||||
| }); | ||||
|  | ||||
| test("Kiosk can start and cancel trip", async ({ page }, testInfo) => { | ||||
| @@ -189,6 +211,29 @@ test("Kiosk can start and finish trip", async ({ page }, testInfo) => { | ||||
|   await expect(page.locator('body')).toContainText('(cox2)'); | ||||
|   await expect(page.locator('body')).toContainText('Ottensheim (25 km)'); | ||||
|   await expect(page.locator('body')).toContainText('Ruderer: cox2, rower2'); | ||||
|    | ||||
|  | ||||
|  | ||||
|   //Ausloggen... | ||||
|   await page.context().clearCookies(); | ||||
|   await page.goto("/auth"); | ||||
|   // Login as admin | ||||
|   await page.getByPlaceholder("Name").click(); | ||||
|   await page.getByPlaceholder("Name").fill("main"); | ||||
|   await page.getByPlaceholder("Name").press("Tab"); | ||||
|   await page.getByPlaceholder("Passwort").fill("admin"); | ||||
|   await page.getByPlaceholder("Passwort").press("Enter"); | ||||
|  | ||||
|   await page.goto("/log/show"); | ||||
|   await page.getByText('(cox2)').click(); | ||||
|   page.once("dialog", (dialog) => { | ||||
|     dialog.accept().catch(() => {}); | ||||
|   }); | ||||
|   await page.getByRole('link', { name: 'Löschen' }).click(); | ||||
|  | ||||
|   //Ausloggen... | ||||
|   await page.getByRole('banner').getByRole('link', { name: 'Logbuch' }).click(); | ||||
|   await page.getByRole('link', { name: 'Ausloggen' }).click(); | ||||
| }); | ||||
|  | ||||
| test("Cox can start and finish trip with cox steering only", async ({ page }, testInfo) => { | ||||
| @@ -241,8 +286,31 @@ test("Cox can start and finish trip with cox steering only", async ({ page }, te | ||||
|  | ||||
|   await page.goto('/log/show'); | ||||
|   await expect(page.locator('body')).toContainText('cox_only_steering_boat'); | ||||
|   await expect(page.locator('body')).toContainText('(cox2)'); | ||||
|   await expect(page.locator('body')).toContainText('(cox2 - handgesteuert)'); | ||||
|   await expect(page.locator('body')).toContainText('Ottensheim (25 km)'); | ||||
|    | ||||
|  | ||||
|  | ||||
|   //Ausloggen... | ||||
|   await page.getByRole('banner').getByRole('link', { name: 'Logbuch' }).click(); | ||||
|   await page.getByRole('link', { name: 'Ausloggen' }).click(); | ||||
|   // Login as admin | ||||
|   await page.getByPlaceholder("Name").click(); | ||||
|   await page.getByPlaceholder("Name").fill("main"); | ||||
|   await page.getByPlaceholder("Name").press("Tab"); | ||||
|   await page.getByPlaceholder("Passwort").fill("admin"); | ||||
|   await page.getByPlaceholder("Passwort").press("Enter"); | ||||
|  | ||||
|   await page.goto("/log/show"); | ||||
|   await page.getByText('(cox2 - handgesteuert)').click(); | ||||
|   page.once("dialog", (dialog) => { | ||||
|     dialog.accept().catch(() => {}); | ||||
|   }); | ||||
|   await page.getByRole('link', { name: 'Löschen' }).click(); | ||||
|  | ||||
|   //Ausloggen... | ||||
|   await page.getByRole('banner').getByRole('link', { name: 'Logbuch' }).click(); | ||||
|   await page.getByRole('link', { name: 'Ausloggen' }).click(); | ||||
| }); | ||||
|  | ||||
| test("Kiosk can start and finish trip in one stop", async ({ page }, testInfo) => { | ||||
| @@ -289,4 +357,27 @@ test("Kiosk can start and finish trip in one stop", async ({ page }, testInfo) = | ||||
|   await expect(page.locator('body')).toContainText('(cox2)'); | ||||
|   await expect(page.locator('body')).toContainText('a (1 km)'); | ||||
|   await expect(page.locator('body')).toContainText('Ruderer: cox2, rower2'); | ||||
|    | ||||
|  | ||||
|  | ||||
|   //Ausloggen... | ||||
|   await page.context().clearCookies(); | ||||
|   await page.goto("/auth"); | ||||
|   // Login as admin | ||||
|   await page.getByPlaceholder("Name").click(); | ||||
|   await page.getByPlaceholder("Name").fill("main"); | ||||
|   await page.getByPlaceholder("Name").press("Tab"); | ||||
|   await page.getByPlaceholder("Passwort").fill("admin"); | ||||
|   await page.getByPlaceholder("Passwort").press("Enter"); | ||||
|  | ||||
|   await page.goto("/log/show"); | ||||
|   await page.getByText('(cox2)').click(); | ||||
|   page.once("dialog", (dialog) => { | ||||
|     dialog.accept().catch(() => {}); | ||||
|   }); | ||||
|   await page.getByRole('link', { name: 'Löschen' }).click(); | ||||
|  | ||||
|   //Ausloggen... | ||||
|   await page.getByRole('banner').getByRole('link', { name: 'Logbuch' }).click(); | ||||
|   await page.getByRole('link', { name: 'Ausloggen' }).click(); | ||||
| }); | ||||
|   | ||||
		Reference in New Issue
	
	Block a user