Skip to content

TST-45: E2E scenario expansion — error states, edge journeys, and degraded modes #712

@Chris0Jeky

Description

@Chris0Jeky

Context

Current E2E (Playwright) coverage focuses on the happy path golden flow and some fixture bootstrap scenarios. Missing: error recovery paths, degraded mode behavior, and edge-case user journeys that real users will encounter.

New E2E Scenarios

Error Recovery Journeys

  1. API down during board load: Backend stops responding → user sees error state → backend recovers → user can retry/refresh without losing context
  2. Network interruption during card drag: Card being dragged, network drops → card snaps back, error shown, no data loss
  3. Session expiry during active work: JWT expires mid-session → user prompted to re-login → returns to same view after login
  4. LLM provider degraded: Chat request when LLM provider is down → user sees degraded message with hint, not raw error
  5. Rate limited: User makes too many requests → sees retry prompt with countdown, not cryptic error

Onboarding and First-Run Edge Cases

  1. Fresh user with no boards: Home view shows appropriate empty state with clear CTA
  2. User creates first board → navigates to it → creates first card: Full first-time flow
  3. User starts capture before creating a board: Verify capture still works and suggests board creation
  4. User applies starter pack → boards appear in sidebar immediately (no refresh needed)

Multi-Board Workflows

  1. User switches between boards rapidly: No data contamination between boards
  2. User has 10+ boards: Sidebar doesn't overflow, board list is scrollable
  3. User deletes a board they're currently viewing: Redirected to another board or home
  4. User archives and restores a board: Board reappears in sidebar with correct state

Review and Proposal Journeys

  1. User has 20 pending proposals: Review view handles list correctly, can scroll/paginate
  2. User approves proposal → board immediately reflects change (no manual refresh)
  3. User rejects proposal → proposal disappears from review queue
  4. User views proposal details → all operations listed with human-readable descriptions
  5. Expired proposal in review: User sees clear "expired" state, cannot approve

Capture Edge Cases

  1. Very long capture text (5000 chars): Accepted, truncated if needed, doesn't break UI
  2. Capture with special characters (emoji, unicode, markdown): Preserved correctly
  3. Rapid sequential captures (10 in 5 seconds): All saved, queue shows all items
  4. Capture while not on a board: Capture saved, associated with most recent board or prompts for board selection

Chat Journeys

  1. Chat with tool-calling: User asks about board state → intermediate tool status indicators shown → final response includes data
  2. Chat history persistence: Close and reopen chat → previous messages still visible
  3. Chat with degraded LLM: Provider fails → user sees degraded message with retry option

Keyboard Navigation

  1. Full keyboard-only board workflow: Create board, add column, add card, move card — all via keyboard
  2. Escape key behavior: In every modal/dialog, Escape closes it without side effects
  3. Tab order: Focus moves through interactive elements in logical order

Dark Mode

  1. Toggle dark mode → all views render correctly (no white-on-white or invisible elements)
  2. Dark mode persists across page refresh

Implementation Notes

  • Use Playwright's `page.route()` to simulate network failures and API errors
  • For session expiry: set a very short JWT lifetime in test config
  • For rate limiting: configure low limits in test config and trigger them
  • For degraded LLM: configure mock provider to return degraded responses
  • Group related scenarios into focused spec files: `error-recovery.spec.ts`, `multi-board.spec.ts`, etc.
  • Use Playwright's visual snapshot capability for dark mode regression

Considerations

  • E2E tests are slow — prioritize the highest-signal scenarios
  • Flakiness risk: network-simulation tests can be timing-sensitive — use deterministic waits
  • Some scenarios need backend cooperation (e.g., rate limiting) — configure via env vars

Metadata

Metadata

Assignees

No one assigned

    Projects

    Status

    Review

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions