cleanup tests

This commit is contained in:
Matthias Mair 2024-04-17 22:23:39 +02:00
parent 0d22a8a559
commit 3f6f3b3aad
No known key found for this signature in database
GPG Key ID: A593429DDA23B66A
3 changed files with 5 additions and 7 deletions

View File

@ -3,6 +3,7 @@ import { defineConfig, devices } from '@playwright/test';
export default defineConfig({ export default defineConfig({
testDir: './tests', testDir: './tests',
fullyParallel: true, fullyParallel: true,
timeout: 60000,
forbidOnly: !!process.env.CI, forbidOnly: !!process.env.CI,
retries: process.env.CI ? 1 : 0, retries: process.env.CI ? 1 : 0,
workers: process.env.CI ? 2 : undefined, workers: process.env.CI ? 2 : undefined,

View File

@ -1,5 +1,5 @@
import { expect, test } from '../baseFixtures.js'; import { test } from '../baseFixtures.js';
import { baseUrl, user } from '../defaults.js'; import { baseUrl } from '../defaults.js';
import { doQuickLogin } from '../login.js'; import { doQuickLogin } from '../login.js';
const newPartName = 'UITESTIN123'; const newPartName = 'UITESTIN123';

View File

@ -1,6 +1,6 @@
import { expect, test } from '@playwright/test'; import { test } from '@playwright/test';
import { baseUrl, user } from '../defaults'; import { baseUrl } from '../defaults';
import { doQuickLogin } from '../login'; import { doQuickLogin } from '../login';
test('PUI - Pages - Part - Pricing', async ({ page }) => { test('PUI - Pages - Part - Pricing', async ({ page }) => {
@ -32,15 +32,12 @@ test('PUI - Pages - Part - Pricing', async ({ page }) => {
await page.getByRole('button', { name: 'BOM Pricing' }).isEnabled(); await page.getByRole('button', { name: 'BOM Pricing' }).isEnabled();
// Overview Graph // Overview Graph
//await page.getByText('BOM PricingOverall Pricing').waitFor();
let graph = page.locator('#pricing-overview-chart'); let graph = page.locator('#pricing-overview-chart');
await graph.waitFor(); await graph.waitFor();
//await graph.screenshot({ path: 'pui_part_pricing_overview.png' });
await graph.getByText('$45').waitFor(); await graph.getByText('$45').waitFor();
await graph.getByText('BOM Pricing').waitFor(); await graph.getByText('BOM Pricing').waitFor();
await graph.getByText('Overall Pricing').waitFor(); await graph.getByText('Overall Pricing').waitFor();
await graph.locator('path').nth(1).hover(); await graph.locator('path').nth(1).hover();
//await graph.screenshot({ path: 'pui_part_pricing_overview_hover.png' });
await page.getByText('min_value : $43').waitFor(); await page.getByText('min_value : $43').waitFor();
// BOM Pricing // BOM Pricing