managarten/.gitignore
Till JS 79d112657c feat(personas): M5.a — Playwright visual suite scaffold
Smallest possible foundation for the persona-driven visual regression
suite (M5 in docs/plans/mana-mcp-and-personas.md). One flow, two
viewports, one persona — enough to prove the stack end-to-end:
seed-script → mana-auth → API login → cookie injection → web app →
screenshot → disk. Extending is copy-paste per flow.

tests/personas/
  playwright.config.ts
    Own config separate from the root tests/e2e/ suite. Two viewports
    (1440×900 desktop Chrome + Pixel 5 mobile) — more can be added
    once baselines settle without quadrupling the review load.
    Diff threshold 0.2 %, animations disabled, snapshots land under
    __snapshots__/{spec}/{arg}-{project}.png. No auto-webServer —
    the whole point is to catch regressions against the real stack
    the user runs, not a hermetic one; if the stack is down, tests
    fail loud.

  fixtures/persona-auth.ts
    Typed Playwright `test.extend` with a `personaKey` worker option
    and a `personaPage` fixture that returns a pre-logged-in Page
    pointed at `/`. Login is API-side: POST /api/v1/auth/login with
    the deterministic HMAC-SHA256 password, parse Set-Cookie headers,
    inject into the browser context. Derivation is a bit-identical
    mirror of scripts/personas/password.ts and
    services/mana-persona-runner/src/password.ts — a 3-way contract.
    Changing one without the others locks the suite out of every
    persona. PERSONAS map exports all 10 catalog emails for typed
    access.

  flows/home.spec.ts
    One smoke flow. Asserts the persona isn't redirected to /login,
    hides any [data-testid="live-time"] so clock widgets don't
    invalidate diffs, captures a full-page screenshot. When this
    goes green, the whole pipeline is plumbed. Copy this file to
    add per-module tours.

  package.json
    @mana/tests-personas workspace. Scripts: `test`, `test:update`,
    `report` (HTML diff viewer).

  README.md
    Prerequisites (stack up + seeded + ideally persona-runner ticked
    once), run recipe, env vars, architecture diagram, extension
    pattern.

root package.json: `pnpm test:personas` + `:update`.
.gitignore: playwright-report-personas/ + test-results/ so generated
artefacts never get committed.

Type-check / list: `playwright test --list` succeeds, 2 tests (one
per viewport) registered for home.spec.ts.

Not attempted in this commit (user action to run the stack):
- Actual baseline capture (needs docker up + db:push + seed:personas
  + ANTHROPIC_API_KEY + diag/tick).
- Additional flows (todo, journal, notes, habits, calendar). They're
  copy-paste per README. Land when the stack is smoked.
- Nightly CI job. Will land once baselines are stable.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-04-23 14:33:06 +02:00

136 lines
1.7 KiB
Text

# Dependencies
node_modules/
.pnpm-store/
# Build outputs
dist/
build/
.next/
.nuxt/
.output/
.svelte-kit/
.astro/
.expo/
android/
ios/
.netlify/
# Turbo
.turbo/
# MCP config (contains API keys)
.mcp.json
# Environment files
.env
.env.local
.env.development.local
.env.test.local
.env.production.local
.env*.local
.env.secrets
# BUT commit the central development env file + the secrets template
!.env.development
!.env.secrets.example
# IDE
.idea/
.vscode/
*.swp
*.swo
*~
# OS files
.DS_Store
Thumbs.db
# Logs
logs/
*.log
npm-debug.log*
yarn-debug.log*
yarn-error.log*
pnpm-debug.log*
# Testing
coverage/
.nyc_output/
test-results/
playwright-report/
playwright-report-personas/
test-results/
.auth-state.json
# TypeScript
*.tsbuildinfo
# Drizzle compiled config files
drizzle.config.js
drizzle.config.d.ts
drizzle.config.js.map
# Compiled JS in packages (src should be TS only)
packages/*/src/**/*.js
packages/*/src/**/*.js.map
packages/*/src/**/*.d.ts
# Cache
.cache/
.parcel-cache/
.eslintcache
.prettiercache
# Expo
*.jks
*.p8
*.p12
*.key
*.mobileprovision
*.orig.*
web-build/
# Native builds (keep for reference but don't track)
# Uncomment if you want to track these:
# !android/
# !ios/
# Sentry
.sentryclirc
# Temporary files
tmp/
temp/
*.tmp
# Package manager locks (keep only pnpm)
package-lock.json
yarn.lock
# Debug
.pnpm-debug.log
# Hive mind sessions
.hive-mind/
# Claude Flow metrics
.claude-flow/
.claude-flow/metrics/
# Mac Mini deployment
.env.macmini
ssh-key-command.txt
# Python
.venv/
__pycache__/
*.py[cod]
*$py.class
*.so
.Python
pip-log.txt
pip-delete-this-directory.txt
# ML Models (large files, downloaded on demand)
mlx_models/
services/mana-sync/server