Skip to content

test: cover coding-context persona routing - #1185

Draft
cursor[bot] wants to merge 1 commit into
mainfrom
cursor/missing-test-coverage-e9d5
Draft

test: cover coding-context persona routing#1185
cursor[bot] wants to merge 1 commit into
mainfrom
cursor/missing-test-coverage-e9d5

Conversation

@cursor

@cursor cursor Bot commented Aug 3, 2026

Copy link
Copy Markdown
Contributor

Summary

  • add regression coverage for coding-context routing in tests/test_developer_persona.py
  • fix detect_coding_context() so strong build/debug prompts are treated as coding work while educational API questions stay in teaching mode

Risky behavior now covered

  • strong engineering prompts like Build an API endpoint for user authentication no longer fall through to a generic assistant role with no coding constraints in the v1 compile path
  • React performance/debug prompts now enter coding mode consistently
  • educational API questions and browser bug reports stay out of coding mode, preventing over-routing regressions

Test files updated

  • tests/test_developer_persona.py

Why these tests materially reduce regression risk

  • this helper sits on a shared prompt-routing path, so a small matching bug can quietly change persona, role, and constraints across many compile requests
  • the new tests protect both sides of the boundary: they assert the positive build/debug cases we want, and the negative explanation/browser cases we must not accidentally classify as coding work

Validation

  • python3 -m pytest tests/test_developer_persona.py tests/test_persona_role_language.py tests/test_domain_coverage.py tests/test_schema_validation.py -q
Open in Web View Automation 

Co-authored-by: Mehmet Özel <madara88645@users.noreply.github.com>
@vercel

vercel Bot commented Aug 3, 2026

Copy link
Copy Markdown

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

Project Deployment Actions Updated (UTC)
compiler Ready Ready Preview Aug 3, 2026 10:06am

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