Skip to content

feat(qa): targeted test command templates + full test discovery in project index#402

Open
OBenner wants to merge 1 commit into
developfrom
feat/targeted-test-commands
Open

feat(qa): targeted test command templates + full test discovery in project index#402
OBenner wants to merge 1 commit into
developfrom
feat/targeted-test-commands

Conversation

@OBenner

@OBenner OBenner commented Jul 6, 2026

Copy link
Copy Markdown
Owner

Summary

Roadmap phase 4 — QA iteration economics. Two connected gaps:

  1. project_index.json (what coder/QA prompts actually read) had almost no test info. ServiceAnalyzer._detect_testing() recognized only Vitest/Jest/pytest and never emitted test_command. Now it delegates to TestDiscovery (all ecosystems from feat(qa): test discovery parity for JVM, .NET, native, and scripting-tail languages #388) and emits testing, e2e_testing, test_command, coverage_command, and targeted_test_command per service.

  2. No way to run a subset of tests. For compiled stacks a full-suite run per QA-fix iteration is expensive. TestDiscovery now produces a targeted_command template with a {target} placeholder:

Style Examples
path-based pytest {target}, npx jest {target}, go test {target}, mix test {target}
filter-based mvn test -Dtest={target}, ./gradlew test --tests {target}, dotnet test --filter "{target}", ctest -R {target}

The Gradle template keeps the wrapper when the project ships one. Frameworks without a reliable targeted form (zig/stack/cabal/make) yield None rather than a guess.

QA agents pick the template up from project_index.json — the LLM does the file→target mapping, deterministic code stays honest.

Testing

tests/test_discovery.py: 72 passed (5 new). New tests/test_service_analyzer_testing.py: 4 passed. Ruff check + format clean.

🤖 Generated with Claude Code

…oject index

Roadmap phase 4 (iteration economics): the coder/QA prompts read
per-service test commands from project_index.json, but
ServiceAnalyzer._detect_testing() only knew Vitest/Jest/pytest and
never emitted test_command at all.

- TestDiscovery: new targeted_command template per framework
  ({target} = path for pytest/jest/go-style runners, name/filter for
  mvn/gradle/dotnet/ctest). Exposed on the result and in to_dict().
- ServiceAnalyzer: _detect_testing now delegates to TestDiscovery,
  emitting testing, e2e_testing, test_command, coverage_command, and
  targeted_test_command for every supported ecosystem, so QA fixers
  can run single tests instead of full suites in compiled stacks.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Signed-off-by: Oleg Miagkov <mrobenner@gmail.com>
@cursor

cursor Bot commented Jul 6, 2026

Copy link
Copy Markdown

Bugbot is not enabled for your account, so this pull request was not reviewed.

Enable Bugbot in the Cursor dashboard to get automatic reviews on future PRs.

@coderabbitai

coderabbitai Bot commented Jul 6, 2026

Copy link
Copy Markdown
Contributor

Warning

Review limit reached

@OBenner, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 3 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro

Run ID: eecf86c4-e97d-4e50-b577-9c00c68577ca

📥 Commits

Reviewing files that changed from the base of the PR and between a6f6538 and 53bb7b1.

📒 Files selected for processing (4)
  • apps/backend/analysis/analyzers/service_analyzer.py
  • apps/backend/analysis/test_discovery.py
  • tests/test_discovery.py
  • tests/test_service_analyzer_testing.py
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/targeted-test-commands

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@sonarqubecloud

sonarqubecloud Bot commented Jul 6, 2026

Copy link
Copy Markdown

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant