Repository navigation
CI: fold last top-level covgap test binaries (#1089) - #1568
Conversation
Assisted-by: Claude Code:claude-opus-5-5
Two coverage-gap files still built as their own test binaries, one of them with a copy of another suite's private harness. They now live in their command's suite, so CI links two fewer test binaries and a change to the config fallback harness lands in one place. - covgap_utils_socket_cli_config.rs is gone. Its SOCKET_DEBUG provenance check joins config_token_and_api_base_url_authenticate in cli_config_fallback.rs, which already builds the same fixture, and now covers human and --json runs. - coverage_fix_scan_hosted_dryrun_vendored.rs moves into the scan suite as scan/hosted_dryrun_vendored.rs, on the suite's shared common and vlt_hosted_common modules. - The scan suite mounts prebuilt_common once instead of three times, so its selftests run once. - scripts/ci-test-durations.json drops the two targets and adds their time to scan and cli_config_fallback. Refs #1089 Assisted-by: Claude Code:claude-opus-5-5
Review follow-ups for the fold into the scan suite: - The hosted dry-run tests use the suite's shared hosted_skipped, warning_detail and envelope::hosted_pins instead of private copies, and the vlt test builds its vendored project with the shared vlt_vendored::vendored_project fixture. - Drop #[serial]: the tests only spawn hermetic children in their own tempdirs against their own mock servers, so they can run in parallel with the rest of the binary. - The config fallback test checks that the SOCKET_DEBUG provenance line stays silent without the flag in --json runs too, as the deleted covgap test did. Refs #1089 Assisted-by: Claude Code:claude-opus-5-5
|
BugBot review Generated by Claude Code |
There was a problem hiding this comment.
✅ Bugbot reviewed your changes and found no new issues!
Comment @cursor review or bugbot run to trigger another review on this PR
Reviewed by Cursor Bugbot for commit 777911b. Configure here.
|
Ready for review at
Generated by Claude Code |
Final review brief: #1568 at
|
LLM Description written by Claude Code:claude-opus-5-5
Refs #1089 (the last two top-level
covgap_*/coverage_fix_*test binaries). The tracking issue stays open: theupdate/andscan/covgap files remain for later slices.Root cause
Two coverage-gap files still built as their own test binaries, and one of them carried a copy of another suite's private harness instead of living in its command's suite.
What changes
covgap_utils_socket_cli_config.rsis deleted (−157 lines). Its harness was a copy ofcli_config_fallback.rs's private helpers. Its one check, theSOCKET_DEBUGprovenance line for a config-sourcedapiBaseUrl, moves intocli_config_fallback.rs::config_token_and_api_base_url_authenticate, which already builds the same fixture. That test now runs human and--json, with and withoutSOCKET_DEBUG: the line prints only under the flag.coverage_fix_scan_hosted_dryrun_vendored.rs→scan/hosted_dryrun_vendored.rs, in thescansuite binary. It now uses the suite's shared helpers:hosted_fixture::{hosted_skipped, warning_detail},common::envelope::{codes_in, hosted_pins}, andvlt_vendored::vendored_projectfor the vlt fixture. That replaces four private copies and a 30-line duplicate of the vlt vendored fixture.#[serial]. They set no process-global state and only spawn hermetic children in their own tempdirs against their own mock servers.clippy::unnecessary_map_on_constructorin the moved file.scan/main.rsmountsprebuilt_commononce. Before, three modules each mounted their own copy.vlt_hosted_common/vendored.rsstill mounts its own copy, because that file is path-included by other suites too. Changing that is out of scope here.scripts/ci-test-durations.jsondrops the two targets and adds their recorded time toscan(12.35 → 13.96 s) andcli_config_fallback(0.18 → 0.26 s), so the shard balance stays the same.Three 4+-word
.containschecks stay inhosted_dryrun_vendored.rs. They pin the "would be written to a new file" variant of theredirect_pnpm_trust_lockfile/redirect_npm_allow_remoteguidance, and the envelope has no structured field for that (rewrittenFilesnames the file but doesn't say whether it is new). Replacing them would need a production change, which is out of scope for a test-only slice.CI cost (lean PR run)
cargo test --workspacebuild compiles and links 2 fewer test binaries: thetestshards,coverageand the e2e build that compiles every CLI test. That is a few seconds of link time per job, so job-minutes go slightly down. No jobs move between tiers.Test evidence
cargo test -p socket-patch-cli --all-features --test cli_config_fallback --test scan: 11 + 245 passed. Before this PR it was 11 + 253, and the drop of 8 is the duplicatedprebuilt_commonselftests. The moved tests all pass in the scan binary:hosted_dryrun_vendored::*5/5.cargo check -p socket-patch-cli --all-features --tests: every test target compiles. A full localcargo test -p socket-patch-cliran out of this session's disk allowance while linking about 240 test binaries, so CI runs the full suite.cargo fmt --all -- --checkandcargo clippy --locked --workspace --all-features -- -D warnings(the CI form) are clean.python3 -m pytest scripts/tests -q: 342 passed, 6 skipped. That includestest_ci_test_shard.pyagainst the updated durations file./code-review highraised 7 findings. Fixed: the dropped--jsonsilence check, three duplicated helpers, the duplicated vlt fixture, and the unneeded#[serial]. Not fixed: thevlt_vendoredsecondprebuilt_commoncopy (pre-existing, shared with other suites; see above). Thewarning_detailname clash went away when the local copy was deleted.🤖 Generated with Claude Code
https://claude.ai/code/session_015kU2j3qoD5buwCAkuEiZaq
Generated by Claude Code