Tweaks, fixes, and launch prep

This commit is contained in:
2026-02-06 19:09:48 -03:00
parent 22b21d254c
commit 2959360d65
34 changed files with 496 additions and 81 deletions

View File

@@ -1,8 +0,0 @@
import { test, expect } from '@playwright/test';
test('homepage has title and main content', async ({ page }) => {
await page.goto('/');
await expect(page).toHaveTitle(/mifi\.dev/);
await expect(page.getByRole('heading', { level: 1 })).toContainText('mifi.dev');
await expect(page.getByRole('main')).toBeVisible();
});

24
e2e/homepage.spec.ts Normal file
View File

@@ -0,0 +1,24 @@
import { test, expect } from '@playwright/test';
test('homepage has title and main content', async ({ page }) => {
await page.goto('/');
// Title and hero (variant-agnostic)
await expect(page).toHaveTitle(/mifi\.(dev|bio)/);
await expect(page.getByRole('heading', { level: 1 })).toContainText('mifi');
// Key landmarks: header, main, footer
await expect(page.getByRole('banner')).toBeVisible();
await expect(page.getByRole('main')).toBeVisible();
await expect(page.getByRole('contentinfo')).toBeVisible();
// Skip link targets main content (a11y)
const skipLink = page.getByRole('link', { name: /skip to main content/i });
await expect(skipLink).toBeVisible();
await expect(skipLink).toHaveAttribute('href', '#main-content');
await expect(page.locator('main#main-content')).toBeVisible();
// At least one link (both variants have link sections)
const linkCount = await page.getByRole('link').count();
expect(linkCount).toBeGreaterThan(0);
});