Skip to content

Commit 0c146a1

Browse files
committed
Revert "does CI pass if I remove the prerendered page?"
This reverts commit 38554d5.
1 parent 0f6c1fe commit 0c146a1

File tree

3 files changed

+16
-0
lines changed

3 files changed

+16
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
// import type { PageServerLoad } from './$types';
2+
3+
export const prerender = true;
4+
5+
// export const load: PageServerLoad = async function load() {
6+
// return {
7+
// message: 'From server load function.',
8+
// };
9+
// };
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
2+
<p>Visit <a href="https://svelte.dev/docs/kit">svelte.dev/docs/kit</a> to read the documentation</p>

dev-packages/e2e-tests/test-applications/sveltekit-cloudflare-pages/tests/demo.test.ts

+5
Original file line numberDiff line numberDiff line change
@@ -4,3 +4,8 @@ test('home page has expected h1', async ({ page }) => {
44
await page.goto('/');
55
await expect(page.locator('h1')).toBeVisible();
66
});
7+
8+
test('prerendered page has expected h1', async ({ page }) => {
9+
await page.goto('/prerender-test');
10+
await expect(page.locator('h1')).toHaveText('From server load function.');
11+
});

0 commit comments

Comments
 (0)