Skip to content

Commit 29674bb

Browse files
committed
Merge release/v5-prerelease (per-command tests)
Brings in #297, which groups the CLI tests into one binary per command and replaces the #257 oracles with golden files. It merges cleanly; this PR's test binaries stay at the top level, as most still do. Clippy and the policy, in-memory, parity, e2e policy, parser, help, scan and get suites pass. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01BKsyzefGhAnPkYmXCwq3H3
2 parents d9dd0ff + b97a1c2 commit 29674bb

123 files changed

Lines changed: 5325 additions & 3349 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

‎CHANGELOG.md‎

Lines changed: 1 addition & 1 deletion

‎crates/socket-patch-cli/CLI_CONTRACT.md‎

Lines changed: 4 additions & 4 deletions

‎crates/socket-patch-cli/src/commands/scan/mod.rs‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3328,7 +3328,7 @@ mod tests {
33283328

33293329
// ---- redirectState envelope block (read-only cross-mode visibility) ----
33303330
// The end-to-end envelope placement (report-only + agent runs carry it,
3331-
// hosted/vendored runs don't) is pinned by `tests/scan_invariants.rs`;
3331+
// hosted/vendored runs don't) is pinned by `tests/scan/scan_invariants.rs`;
33323332
// these pin the block builder's own gates and shape.
33333333

33343334
/// Pins present ⇒ the block exists with each pin's canonical purl +

crates/socket-patch-cli/tests/apply_invariants.rs renamed to crates/socket-patch-cli/tests/apply/apply_invariants.rs

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -682,10 +682,8 @@ fn unmatched_purl_exit_semantics_are_pinned() {
682682
assert_eq!(v2["status"], "partialFailure", "{v2}");
683683
}
684684

685-
#[path = "vlt_hosted_common/mod.rs"]
686-
mod vlt_hosted_common;
687-
#[path = "vlt_hosted_common/vendored.rs"]
688-
mod vlt_vendored;
685+
use crate::vlt_hosted_common;
686+
use crate::vlt_vendored;
689687

690688
/// A vlt-vendored purl: `apply` yields it to the vendor ledger (the
691689
/// committed dir artifact is what vlt installs), leaves `.socket/`
File renamed without changes.

crates/socket-patch-cli/tests/cli_gem_variant_mismatch_policy.rs renamed to crates/socket-patch-cli/tests/apply/cli_gem_variant_mismatch_policy.rs

File renamed without changes.

crates/socket-patch-cli/tests/covgap_commands_apply.rs renamed to crates/socket-patch-cli/tests/apply/covgap_commands_apply.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,8 +39,7 @@ use serde_json::{json, Value};
3939
use wiremock::matchers::{method, path};
4040
use wiremock::{Mock, MockServer, ResponseTemplate};
4141

42-
#[path = "common/mod.rs"]
43-
mod common;
42+
use crate::common;
4443

4544
use common::{git_sha256, parse_json_envelope, run_with_env};
4645

crates/socket-patch-cli/tests/e2e_safety_advisories.rs renamed to crates/socket-patch-cli/tests/apply/e2e_safety_advisories.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,7 @@
2727
2828
use std::path::Path;
2929

30-
#[path = "common/mod.rs"]
31-
mod common;
30+
use crate::common;
3231

3332
use common::{
3433
git_sha256, parse_json_envelope, run_with_env, write_blob, write_minimal_manifest, PatchEntry,

crates/socket-patch-cli/tests/in_process_gem_config_warning.rs renamed to crates/socket-patch-cli/tests/apply/in_process_gem_config_warning.rs

File renamed without changes.

crates/socket-patch-cli/tests/in_process_gem_fallback_home.rs renamed to crates/socket-patch-cli/tests/apply/in_process_gem_fallback_home.rs

File renamed without changes.

0 commit comments

Comments
 (0)