mirror of
https://github.com/jamiepine/voicebox.git
synced 2026-09-16 05:10:42 -07:00
e2e/ drives the web build (vite preview) against a per-worker uvicorn: each Playwright worker boots its own backend on its own port with a temp cwd, so SQLite and audio files are fully isolated and parallel- safe. The page fixture seeds the persisted voicebox-server store with the worker's URL before any script runs. VOICEBOX_FAKE_TTS=1 short-circuits get_tts_backend_for_engine to a backend that synthesizes a sine tone sized to the text — the real task queue, SSE progress, history rows, and audio serving all run, only inference is fake. backend/requirements-ci.txt is the slim dependency set validated to boot the app on a CPU-only runner. Specs: startup, settings layout, seeded profile in /voices, and generate-to-completed-audio through the full pipeline.
17 lines
659 B
TypeScript
17 lines
659 B
TypeScript
import { expect, test } from '../fixtures';
|
|
|
|
test('app boots against the backend and shows the main editor', async ({ page }) => {
|
|
await page.goto('/');
|
|
|
|
await expect(page.getByRole('heading', { name: 'Voicebox' })).toBeVisible();
|
|
await expect(page.getByRole('button', { name: 'Create Voice' }).first()).toBeVisible();
|
|
});
|
|
|
|
test('settings layout renders its pages', async ({ page }) => {
|
|
await page.goto('/settings/about');
|
|
|
|
await expect(page.getByText('General', { exact: true })).toBeVisible();
|
|
await expect(page.getByText('Changelog', { exact: true })).toBeVisible();
|
|
await expect(page.getByText('About', { exact: true })).toBeVisible();
|
|
});
|