Skip to content

test(examples-chat): fix no_fixture_match for contact-form welcome chip#451

Merged
blove merged 1 commit into
mainfrom
claude/aimock-contact-form-fixture
May 18, 2026
Merged

test(examples-chat): fix no_fixture_match for contact-form welcome chip#451
blove merged 1 commit into
mainfrom
claude/aimock-contact-form-fixture

Conversation

@blove
Copy link
Copy Markdown
Contributor

@blove blove commented May 18, 2026

Summary

Eliminates the recurring `No fixture matched` / `Background run failed` cascade in the langgraph backend log during every `examples/chat — e2e` CI run.

Root cause: `lifecycle.spec.ts:61` ('selecting a welcome suggestion submits and clears welcome state') clicks the 'Demo: render a contact form' welcome chip, which sends the full chip value as the LLM prompt:

Show me a contact form with fields for name, email address, subject, and a multi-line message, plus a Send button.

No fixture matched this prompt. The test passed (it doesn't await the assistant response), but the langgraph backend kept retrying and emitting 404 tracebacks into the log on every run.

Fix

Add a fixture matching the substring `'contact form'` (aimock's `userMessage` matching is includes-based) that returns a `render_a2ui_surface` tool call building the requested contact-form spec (name / email / subject / message + Send button) — modeled directly on the existing `a2ui-surface.json` (feedback form).

Why a fixture instead of changing the test

  • The test specifically validates the chip-click user affordance — short-circuiting it (typing the chip label instead of clicking) would defeat the test's purpose.
  • aimock's substring match keeps the fixture key tight (`'contact form'`) so it won't shadow existing fixtures or accidentally match unrelated future prompts.

Test plan

  • `pnpm nx e2e examples-chat-angular --grep "selecting a welcome suggestion"` — green; langgraph log shows `Background run succeeded` (was: 4 lines of 404 tracebacks)
  • Full `pnpm nx e2e examples-chat-angular` — no fixture-related regressions; pre-existing local flakes (error-handling, markdown-surfaces, regenerate, send-receive) unchanged
  • CI

🤖 Generated with Claude Code

`lifecycle.spec.ts:61` ('selecting a welcome suggestion submits and clears
welcome state') clicks the 'Demo: render a contact form' welcome chip,
which sends the full chip value as the LLM prompt:

  'Show me a contact form with fields for name, email address, subject,
   and a multi-line message, plus a Send button.'

No fixture matched this prompt, so the test's fire-and-forget click left
4 'No fixture matched' / 'Background run failed' tracebacks in the
langgraph backend log every CI run since the chip was added. The test
itself passed because it didn't await the assistant response.

Add a fixture matching the substring 'contact form' (aimock's
userMessage match is includes-based) that returns a render_a2ui_surface
tool call building the contact form spec the prompt asked for. Verified
locally: lifecycle:61 now logs 'Background run succeeded' instead of
the 404 cascade.

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

vercel Bot commented May 18, 2026

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

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

Request Review

@blove blove merged commit e1fa045 into main May 18, 2026
18 checks passed
@blove blove deleted the claude/aimock-contact-form-fixture branch May 18, 2026 23:56
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