Skip to content

test(e2e-harness): delete broken test-helpers.spec.ts; document strategy#499

Merged
blove merged 1 commit into
mainfrom
claude/harness-spec-fix
May 21, 2026
Merged

test(e2e-harness): delete broken test-helpers.spec.ts; document strategy#499
blove merged 1 commit into
mainfrom
claude/harness-spec-fix

Conversation

@blove
Copy link
Copy Markdown
Contributor

@blove blove commented May 20, 2026

Summary

Fixes a silent Library lint failure and documents the harness's testing strategy.

Bug fix

`libs/e2e-harness/src/test-helpers.spec.ts` imported `SendPromptAndWaitOptions` which was removed in PR #472 (harness helper consolidation). This left a `tsc --noEmit` error in the harness lint target that has been silently failing the `Library — lint / test / build` gate. The chat-sidenav-scrim no-output-native noise (resolved by #485) was masking it; subsequent admin-merges let the regression slide.

Resolution

  • Delete the spec. Its original purpose ("locks in the type contract") was already covered by tsc itself; the deleted type meant the spec was verifying a removed API.
  • Document the testing strategy in a header block on `test-helpers.ts`. The 3 Playwright-dependent helpers (submitAndWaitForResponse, sendPromptAndWaitForInterrupt, clickInterruptActionAndWaitFinal) are exercised end-to-end by the 24 cockpit cap aimock e2es in the matrix. `startAimock` (the only helper testable without a Page) has its own `aimock-runner.spec.ts` in the same directory.

Identified during

Post-Task-#4 e2e audit (item #8).

Test plan

  • CI `Library — lint / test / build` now PASSES (this fix should unblock the gate that's been failing).
  • Reviewer: `npx tsc --noEmit` clean from `libs/e2e-harness/` directory.

🤖 Generated with Claude Code

The spec imported `SendPromptAndWaitOptions` which was removed in PR #472
(harness helper consolidation), leaving a tsc error in the lint target
that has been silently failing the Library — lint gate. The chat-sidenav-
scrim no-output-native noise (resolved by #485) was masking it; subsequent
admin-merges let it through.

Two-part fix:

1. Delete the spec. Its original purpose ("locks in the type contract")
   was already covered by tsc itself; the deleted type meant the spec
   was just verifying a removed API.

2. Document the testing strategy in a header block on test-helpers.ts
   so future contributors know the absence of unit tests is intentional:
   - The 3 Playwright-dependent helpers are exercised end-to-end by the
     24 cockpit cap aimock e2es in the matrix.
   - `startAimock` (the only helper testable without a Page) has its own
     aimock-runner.spec.ts in the same directory.

Identified during the post-Task-#4 e2e audit (item #8).

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@vercel
Copy link
Copy Markdown

vercel Bot commented May 20, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
threadplane Ready Ready Preview, Comment May 20, 2026 11:53pm

Request Review

@blove blove merged commit 2da4f47 into main May 21, 2026
39 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant