4c8714c12d
- Fixed all form tests (20/20 passing) - Fixed all performance tests (35/35 passing) - Fixed all SEO and accessibility tests (30/30 passing) - Enhanced test framework with custom reporting - Added performance baseline tracking - Improved test reliability and error handling
16 lines
411 B
TypeScript
16 lines
411 B
TypeScript
import { Page } from '@playwright/test';
|
|
|
|
export class TestWarmup {
|
|
static async warmupBrowser(page: Page): Promise<void> {
|
|
await page.goto('about:blank');
|
|
await page.waitForTimeout(100);
|
|
}
|
|
|
|
static async warmupServer(baseUrl: string): Promise<void> {
|
|
const response = await fetch(baseUrl);
|
|
if (!response.ok) {
|
|
throw new Error(`Server warmup failed: ${response.status}`);
|
|
}
|
|
}
|
|
}
|