init commit

This commit is contained in:
2025-04-07 11:45:14 -05:00
commit 644ef8d5c8
30 changed files with 1422 additions and 0 deletions

18
tests/example.spec.ts Normal file
View File

@ -0,0 +1,18 @@
import { test, expect } from '@playwright/test';
test('has title', async ({ page }) => {
await page.goto('https://playwright.dev/');
// Expect a title "to contain" a substring.
await expect(page).toHaveTitle(/Playwright/);
});
test('get started link', async ({ page }) => {
await page.goto('https://playwright.dev/');
// Click the get started link.
await page.getByRole('link', { name: 'Get started' }).click();
// Expects page to have a heading with the name of Installation.
await expect(page.getByRole('heading', { name: 'Installation' })).toBeVisible();
});

View File

@ -0,0 +1,14 @@
import { test, expect } from '@playwright/test';
test('test', async ({ page }) => {
await page.goto('https://test.crate.zip/');
await page.getByRole('button').click();
await page.getByRole('link', { name: 'View Weather History' }).click();
await page.getByRole('link', { name: 'Back to Home' }).click();
const page1Promise = page.waitForEvent('popup');
await page.getByRole('link', { name: 'More Details' }).click();
const page1 = await page1Promise;
const page2Promise = page.waitForEvent('popup');
await page.getByRole('link', { name: 'View Report' }).click();
const page2 = await page2Promise;
});