Skip to content

feat(ctest): add compact output filter#2250

Open
jsiu93 wants to merge 2 commits into
rtk-ai:developfrom
jsiu93:fix/ctest-filter-2237
Open

feat(ctest): add compact output filter#2250
jsiu93 wants to merge 2 commits into
rtk-ai:developfrom
jsiu93:fix/ctest-filter-2237

Conversation

@jsiu93

@jsiu93 jsiu93 commented Jun 4, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Add rtk ctest with compact CTest output for green runs and preserved failing-test details.
  • Register ctest in hook rewrite/discover, pipe filtering, tracking, and TOML shadow warnings.
  • Preserve explicit detail modes by passing through verbose/show-only/help/version invocations.

Closes #2237

Test plan

  • cargo fmt -- --check
  • cargo test ctest
  • cargo test
  • cargo clippy -- -D warnings
  • Manual: cargo run --quiet -- rewrite "ctest -R smoke --output-on-failure"
  • Manual: cargo run --quiet -- pipe --filter ctest with sample CTest output

All PRs must target the develop branch.

@jsiu93 jsiu93 force-pushed the fix/ctest-filter-2237 branch from 599e93d to e8493eb Compare June 27, 2026 03:16
@jsiu93 jsiu93 force-pushed the fix/ctest-filter-2237 branch from 3d3e3d5 to 3964bea Compare July 3, 2026 02:14
@jsiu93

jsiu93 commented Jul 3, 2026

Copy link
Copy Markdown
Contributor Author

@KuSh @aeppling
Looks like the benchmark failure comes from input variance in the curl json case.

That benchmark calls https://mockhttp.org/json separately for raw curl and rtk curl. The endpoint can return different JSON payloads between requests, so the token counts may be measured against different inputs.

Here is a local example showing two different response shapes:

  ❯ rtk curl -s https://mockhttp.org/json
  {"message":"Hello from MockHTTP","timestamp":"2026-07-03T02:05:44.002Z","status":"success","code":200}

  ❯ curl -s https://mockhttp.org/json
  {"metrics":{"cpu":45.2,"memory":78.5,"disk":62.3,"network":{"inbound":"1.2MB/s","outbound":"0.8MB/s"},"uptime":"15 days","services":[{"name":"api","status":"healthy"},{"name":"database","status":"healthy"},{"name":"cache","status":"warning"}]}}

A deterministic local HTTP fixture, or capturing one response and feeding the same body to both commands, should make this benchmark stable.

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.

Add rtk ctest filter (summarize on pass, keep failing-test output)

1 participant