summaryrefslogtreecommitdiff
path: root/tests/example.spec.ts
diff options
context:
space:
mode:
authorErich Eckner <git@eckner.net>2023-12-04 19:20:16 +0100
committerErich Eckner <git@eckner.net>2023-12-04 19:20:16 +0100
commit64f3e1d491cfd08cc8234b3d6504975674cf7cee (patch)
treefa00c55690221482eac1fe2c39a9f5fa75c5f657 /tests/example.spec.ts
downloadMilchtankstelle-64f3e1d491cfd08cc8234b3d6504975674cf7cee.tar.xz
initial commit
Diffstat (limited to 'tests/example.spec.ts')
-rw-r--r--tests/example.spec.ts18
1 files changed, 18 insertions, 0 deletions
diff --git a/tests/example.spec.ts b/tests/example.spec.ts
new file mode 100644
index 0000000..54a906a
--- /dev/null
+++ b/tests/example.spec.ts
@@ -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();
+});