Skip to content

[T-117] Playwright E2E harness: compose-based stack, seeded DB, fixtures, axe helper, e2e.yml workflow #186

Closed

Description

@CodewithJha

Task T-117 · Milestone M8 — Dashboard · Size M · Priority P0 · Epic #8

Implements NFR-MNT-001 · NFR-ACC-001

Branch test/t-117-playwright-e2e-harness-compose-based — one task = one branch = one PR (doc 32 §6)

Summary

Create web/e2e/ Playwright config (Chromium + Firefox), global setup that boots the compose stack (core + app + worker-k2d) with the seeded DB, page-object helpers, an expectNoA11yViolations(page) axe helper, trace/video on failure, and .github/workflows/e2e.yml (on PR to main for web/**/api/** + nightly).

Context / motivation

Doc 18 §4.10: E2E and accessibility gates run against the real stack.

Scope

In scope

  • Artifacts upload (traces, screenshots) on failure.

Implementation guidance

  • web/playwright.config.ts: projects chromium and firefox; baseURL from E2E_BASE_URL (default http://localhost:8080); trace: 'retain-on-failure', video: 'retain-on-failure', retries: 1 on CI; globalSetup: './e2e/global-setup.ts'.
  • global-setup.ts: docker compose --profile core --profile app up -d --wait with an E2E env file (docker/e2e.env: small budgets, ROBOPROBE_K2D_REPLICAS=2), load seed_small.sql via load_seed.py, wait for /health/ready; teardown collects docker compose logs into the report.
  • Helpers: e2e/pages/*.ts page objects (Bench, Wizard, Console, Run, Casebook, Atlas); e2e/a11y.ts expectNoA11yViolations(page, {include?, disableRules?}) with @axe-core/playwright, failing on serious|critical.
  • .github/workflows/e2e.yml: triggers pull_request (paths web/**, backend/src/roboprobe/api/**, docker/**), nightly schedule, workflow_dispatch; builds images locally (no push), runs Playwright, uploads playwright-report/ and compose logs; permissions: contents: read.
  • Standards: respect the layering contracts (doc 16 §2) and conventions in doc 34; no hard-coded tunables — thresholds/defaults come from typed settings (doc 27); no magic numbers (ruff PLR2004); public APIs typed (mypy strict) and documented.

Acceptance criteria

  • Sample smoke spec (Bench renders, axe clean) green in CI.
  • Run time < 10 min.
  • Failure artefacts uploaded and linked in the job summary.
  • Global teardown always runs (even on failure).
  • Tests listed below added and green in CI; coverage of new code meets the gate in doc 18 §3.
  • Docs, config reference and CHANGELOG Unreleased updated where behaviour, keys or interfaces changed.
  • Definition of Done (doc 32 §3) satisfied.

Tests required

  • The harness itself + smoke spec.

Dependencies

Blocked by: #185 (T-116), #159 (T-107), #97 (T-047)

Blocks: #187 (T-118)

Parallelization notes

Files / paths owned by this task — avoid editing other paths; shared files (pyproject.toml entry points, cli/main.py, api/routers/__init__.py, router.tsx, docker/compose.yaml, ci.yml) are append-only:

  • web/e2e/**
  • web/playwright.config.ts
  • .github/workflows/e2e.yml

Enables T-118 specs in parallel (one spec file each).

Definition of Done

Per doc 32 §3 and AGENTS.md §5: lint, format, mypy strict and import-linter green; tests added and passing; docs updated; PR template completed with Closes #<this issue>; Conventional Commit messages referencing T-117 (doc 16 §6); commits authored only by the repository owner identity (AGENTS.md §4); CI green; reviewer checklist (doc 32 §5.1) satisfied.

References

Design docs: doc 18 §4.10 · doc 20 §1 · doc 13 §7 · doc 17 §4 · doc 31 §3

Requirements: NFR-MNT-001 · NFR-ACC-001 (traceability: doc 28)

External:

Activity

  1. added this to the M8 — Dashboard milestone on Nov 19, 2026
  2. added
    type:testTest suites and test infrastructure
    area:ciCI/CD workflows
    priority:P0Critical path / blocks others
    taskChild task of a milestone epic
    on Nov 19, 2026
  3. CodewithJha commented on Nov 22, 2026

    @CodewithJha
    OwnerAuthor

    Shipped on main (Playwright E2E stack: #332, #330).

  4. added a commit that references this issue on Nov 22, 2026
    9669e5f
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:ciCI/CD workflowsarea:dashboardReact web dashboardmilestone:M8M8 — Dashboardpriority:P0Critical path / blocks otherssize:M1-3 daystaskChild task of a milestone epictype:testTest suites and test infrastructure

    Projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions