From 25ef50f35885e79a1fd297c45309109d2134c6ba Mon Sep 17 00:00:00 2001 From: Valentin Brandl Date: Sun, 18 Aug 2024 15:46:46 +0200 Subject: [PATCH] Add test for page --- tests/page.test.ts | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 tests/page.test.ts diff --git a/tests/page.test.ts b/tests/page.test.ts new file mode 100644 index 0000000..7ffec07 --- /dev/null +++ b/tests/page.test.ts @@ -0,0 +1,10 @@ +import { expect, test } from '@playwright/test'; + +test('contains header text', async ({ playwright }) => { + const context = await playwright.request.newContext(); + const response = await context.get(''); + await expect(response.status()).toBe(200); + + const body = (await response.body()).toString(); + await expect(body).toContain('Gabi und Hannes Fotochallenge'); +});