From 55aa163bc0fe28493a441df09655b3d063b66e2b Mon Sep 17 00:00:00 2001 From: Nicola Clark Date: Fri, 11 Oct 2024 00:03:49 -0500 Subject: [PATCH] created a test --- .gitignore | 3 +++ tests/test.ts | 6 ++++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/.gitignore b/.gitignore index 79518f7..7c08dae 100644 --- a/.gitignore +++ b/.gitignore @@ -19,3 +19,6 @@ Thumbs.db # Vite vite.config.js.timestamp-* vite.config.ts.timestamp-* + +# tests +test-results diff --git a/tests/test.ts b/tests/test.ts index a67e4e7..28760fc 100644 --- a/tests/test.ts +++ b/tests/test.ts @@ -1,6 +1,8 @@ import { expect, test } from '@playwright/test'; -test('home page has expected h1', async ({ page }) => { +test('page has headline', async ({ page }) => { await page.goto('/'); - await expect(page.locator('h1')).toBeVisible(); + const headline = page.locator('header h1'); + await expect(headline).toBeVisible(); + await expect(headline).toHaveText('resumarkdown'); });