Worktrunk is a CLI for Git worktree management, designed for parallel AI agent workflows
fix: redact PWD in snapshot env blocks (#1928)
Maximilian Roosa2fb7a7682da
diff --git a/tests/common/mod.rs b/tests/common/mod.rsindex d0a5243ae..a67899f60 100644--- a/tests/common/mod.rs+++ b/tests/common/mod.rs@@ -2432,6 +2432,7 @@ pub fn add_standard_env_redactions(settings: &mut insta::Settings) {// Windows: etcetera uses APPDATA for config_dir()settings.add_redaction(".env.APPDATA", "[TEST_CONFIG_HOME]");settings.add_redaction(".env.PATH", "[PATH]");+ settings.add_redaction(".env.PWD", "[PWD]");// Mock commands directory (temp path for mock gh/glab binaries)settings.add_redaction(".env.MOCK_CONFIG_DIR", "[MOCK_CONFIG_DIR]");// OpenCode config directory (platform-independent override for tests)diff --git a/tests/snapshots/integration__integration_tests__merge__merge_cwd_removed_hint_fallback_to_list.snap b/tests/snapshots/integration__integration_tests__merge__merge_cwd_removed_hint_fallback_to_list.snapindex e046e92a8..a47b1157d 100644--- a/tests/snapshots/integration__integration_tests__merge__merge_cwd_removed_hint_fallback_to_list.snap+++ b/tests/snapshots/integration__integration_tests__merge__merge_cwd_removed_hint_fallback_to_list.snap@@ -21,9 +21,10 @@ info:LC_ALL: CMOCK_CONFIG_DIR: "[MOCK_CONFIG_DIR]"NO_COLOR: ""+ OPENCODE_CONFIG_DIR: "[TEST_OPENCODE_CONFIG]"PATH: "[PATH]"PSModulePath: ""- PWD: /private/var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmppIn3mC/repo+ PWD: "[PWD]"RUST_LOG: warnSHELL: ""TERM: alacritty@@ -35,6 +36,7 @@ info:WORKTRUNK_TEST_DELAYED_STREAM_MS: "-1"WORKTRUNK_TEST_EPOCH: "1735776000"WORKTRUNK_TEST_NUSHELL_ENV: "0"+ WORKTRUNK_TEST_OPENCODE_INSTALLED: "0"WORKTRUNK_TEST_POWERSHELL_ENV: "0"WORKTRUNK_TEST_SKIP_URL_HEALTH_CHECK: "1"XDG_CONFIG_HOME: "[TEST_CONFIG_HOME]"diff --git a/tests/snapshots/integration__integration_tests__merge__merge_cwd_removed_hint_no_recovery.snap b/tests/snapshots/integration__integration_tests__merge__merge_cwd_removed_hint_no_recovery.snapindex 938a54040..a47b1157d 100644--- a/tests/snapshots/integration__integration_tests__merge__merge_cwd_removed_hint_no_recovery.snap+++ b/tests/snapshots/integration__integration_tests__merge__merge_cwd_removed_hint_no_recovery.snap@@ -21,9 +21,10 @@ info:LC_ALL: CMOCK_CONFIG_DIR: "[MOCK_CONFIG_DIR]"NO_COLOR: ""+ OPENCODE_CONFIG_DIR: "[TEST_OPENCODE_CONFIG]"PATH: "[PATH]"PSModulePath: ""- PWD: /private/var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmp782Z3R/repo.feature+ PWD: "[PWD]"RUST_LOG: warnSHELL: ""TERM: alacritty@@ -35,6 +36,7 @@ info:WORKTRUNK_TEST_DELAYED_STREAM_MS: "-1"WORKTRUNK_TEST_EPOCH: "1735776000"WORKTRUNK_TEST_NUSHELL_ENV: "0"+ WORKTRUNK_TEST_OPENCODE_INSTALLED: "0"WORKTRUNK_TEST_POWERSHELL_ENV: "0"WORKTRUNK_TEST_SKIP_URL_HEALTH_CHECK: "1"XDG_CONFIG_HOME: "[TEST_CONFIG_HOME]"diff --git a/tests/snapshots/integration__integration_tests__merge__merge_post_merge_command_failure.snap b/tests/snapshots/integration__integration_tests__merge__merge_post_merge_command_failure.snapindex 4801b4f2d..a47b1157d 100644--- a/tests/snapshots/integration__integration_tests__merge__merge_post_merge_command_failure.snap+++ b/tests/snapshots/integration__integration_tests__merge__merge_post_merge_command_failure.snap@@ -21,9 +21,10 @@ info:LC_ALL: CMOCK_CONFIG_DIR: "[MOCK_CONFIG_DIR]"NO_COLOR: ""+ OPENCODE_CONFIG_DIR: "[TEST_OPENCODE_CONFIG]"PATH: "[PATH]"PSModulePath: ""- PWD: /private/var/folders/wf/s6ycxvvs4ln8qsdbfx40hnc40000gn/T/.tmpREIpNJ/repo+ PWD: "[PWD]"RUST_LOG: warnSHELL: ""TERM: alacritty@@ -35,6 +36,7 @@ info:WORKTRUNK_TEST_DELAYED_STREAM_MS: "-1"WORKTRUNK_TEST_EPOCH: "1735776000"WORKTRUNK_TEST_NUSHELL_ENV: "0"+ WORKTRUNK_TEST_OPENCODE_INSTALLED: "0"WORKTRUNK_TEST_POWERSHELL_ENV: "0"WORKTRUNK_TEST_SKIP_URL_HEALTH_CHECK: "1"XDG_CONFIG_HOME: "[TEST_CONFIG_HOME]"