import { describe, it, expect } from 'vitest'; import { readFileSync, existsSync } from 'node:fs'; describe('locale routing', () => { it('builds /en/ and /fr/ pages with correct lang attributes', () => { const en = readFileSync('dist/en/index.html', 'utf-8'); const fr = readFileSync('dist/fr/index.html', 'utf-8'); expect(en).toContain('lang="en"'); expect(fr).toContain('lang="fr"'); }); it('does not build an unprefixed root page', () => { expect(existsSync('dist/index.html')).toBe(false); }); });