Skip to content

T-UU4J-pumice-real-backend-e2e

State: planning/proposed · Impact: medium · Complexity: large

Move pumice’s Playwright suite off its browser mock and onto the real backend over HTTP in a scratch root. Pumice is the first Tauri app to move, so this task also builds the shared pieces the other Tauri apps reuse: a headless server helper and the scratchTauriApp adapter.

LocationRole today
apps/pumice/src-tauri/src/api/transport/http/generated.rsOntogen-generated Axum routes over the API handlers
apps/pumice/src-tauri/src/lib.rsThe Tauri setup serves those routes on a hardcoded 127.0.0.1:4321 with permissive CORS; there is no headless bin
apps/pumice/src-nuxt/app/generated/transport.tsThe web build already has an HTTP transport
apps/pumice/src-nuxt/app/plugins/browser-mock.client.ts, app/utils/browser-mock.tsDev-only IPC stand-in with fixtures; installed when import.meta.dev and no Tauri
apps/pumice/src-nuxt/tests/e2e/2 Playwright specs against bun run dev on 18134 and the mock
apps/pumice/moon.ymlNo e2e task
apps/pumice/src-tauri/src/commands/data.rsResolves state through fleet_tauri::AppDirs::resolve(app)
dev-ports.yamlpumice-http 18133 (unused by the code), pumice-e2e 18134

A pumice-server bin builds pumice state from fleet dirs with no Tauri window and serves the generated routes, a resolved-paths endpoint and the static web build on one port. The server main is a shared Rust helper (in packages/rust/fleet-tauri or a new packages/rust crate): given an app router and its state, it takes the port from args or env, adds the resolved-paths route, serves the SPA and handles shutdown. A scratchTauriApp adapter in @sksizer/app-harness launches any bin built on that helper. The pumice suite runs through it, under a moon e2e task. The desktop app reads its HTTP port from dev-ports.yaml’s pumice-http instead of 4321.

  1. Split state construction out of the Tauri setup so a bin can build it from fleet dirs, without an AppHandle.
  2. Write the shared server helper; add the resolved-paths route it serves.
  3. Add the pumice-server bin on the helper.
  4. Add scratchTauriApp to the harness.
  5. Port the Playwright suite; replace fixture data with seeded state in the scratch root. Add the moon e2e task.
  6. Delete the mock if no prototype or story uses it.
AreaNote
apps/pumice/src-tauri/State split, pumice-server bin
apps/pumice/src-nuxt/Suite, mock removal
apps/pumice/moon.ymlE2e task
packages/rust/Shared headless server helper
packages/ts/app-harness/scratchTauriApp
  • AC-1: moon run pumice:e2e passes against pumice-server in a scratch root, with the isolation check on.
  • AC-2: No e2e spec imports or relies on browser-mock.
  • AC-3: The desktop app still serves its HTTP API, on the pumice-http port.
  • AC-4: The helper and scratchTauriApp carry no pumice-specific names, and their READMEs show how another Tauri app adopts them.
  • Desktop smoke.
  • Other Tauri apps (T-KOTJ, T-AAR2, T-TLET).
  • T-NNAG so pumice state follows FLEET_ROOT.
  • T-4HBC for the harness.
  • Pumice already has the HTTP half; the gap is a headless entry point and the e2e wiring.
  • Agentpants has the same shape (generated Axum routes served in-app on a hardcoded port), so the helper is written for both from the start.

T-NNAG, T-4HBC


← Back to Tasks