# ISIS v2 WS15-007: UI E2E Journeys for Creator/Reviewer/Operator Personas

## Scope

`WS15-007` implements role-aware UI journey coverage for ISIS web personas:

- creator: workflow authoring and execution handoff;
- reviewer: side-by-side output consistency review and approval loop actions;
- operator: RunPod and provider telemetry operations flow.

## Research and Existing Implementation Alignment

Before implementation, existing UI test and navigation surfaces were reviewed:

- existing ISIS app-shell E2E integration harness:
  - `apps/isis/web/src/App.e2e.spec.tsx`
- role-aware context navigation model:
  - `apps/isis/web/src/components/AppLayout.tsx`
- layout interaction and keyboard/accessibility journeys:
  - `apps/isis/web/src/components/AppLayout.spec.tsx`
- repo-level browser E2E infrastructure (Playwright):
  - `testing/e2e/playwright.config.ts`

Findings:

- ISIS persona navigation already exists in `AppLayout` but lacked explicit
  journey assertions proving creator/reviewer/operator end-to-end task flows.
- existing `App.e2e.spec.tsx` had broad surface checks, but no persona-scoped
  journey tests and no CI gate dedicated to persona paths.
- ISIS web Vitest resolution had a local package-entry gap for `@isis/client`
  that blocked repeatable app-shell E2E execution in this workspace.

## Deliverables

1. Added executable web test resolution aliases

- `apps/isis/web/vite.config.ts`
- `apps/isis/web/vitest.config.ts`

Added alias mapping:

- `@isis/client` -> `libs/isis/client/src/index.ts`

This removes local package-entry resolution drift and ensures persona E2E
journeys run from source without requiring prebuilt SDK artifacts.

2. Added persona journey coverage in ISIS app-shell E2E suite

- `apps/isis/web/src/App.e2e.spec.tsx`

Implemented persona journeys:

- creator persona journey:
  - validates workflow definition, creates workflow, and submits workflow run;
- reviewer persona journey:
  - opens comparison workspace with baseline/candidate outputs, records review
    decisions/comments, resolves comment state, and locks baseline;
- operator persona journey:
  - exercises RunPod and provider operations snapshots through navigation and
    refresh actions.

3. Added CI gate for persona journeys

- `.github/workflows/ci.yml`

Added `isis-api-route-contracts` step:

- `pnpm --filter @isis/web exec vitest run src/App.e2e.spec.ts -t "persona"`

## Verification Commands

```bash
pnpm --filter @isis/web exec vitest run src/App.e2e.spec.ts -t "persona" --reporter=dot
node scripts/isis/generate-remediation-backlog-v2.mjs
node scripts/isis/validate-v2-compliance-gate.mjs
```

## Verification Notes

- Persona tests are intentionally scoped with `-t "persona"` so CI enforces the
  new role-based journeys deterministically without coupling to unrelated legacy
  app-shell scenarios.
- Coverage validates permission/context shaping and concrete user actions for
  creator, reviewer, and operator pathways.
