Assert that an error string carries the two markers of a remote-side canonicalisation refusal: `resolves to` (proving `realpath -e` ran) and `outside the` + `sandbox workspace` (proving the boundary check fired). miette renders the long single-line error wrapped across multiple lines at terminal width and inserts a `│ ` continuation marker, so a single long substring like `"outside the sandbox wo
(err: &str, label: &str)
| 443 | /// long substring like `"outside the sandbox workspace"` is fragile — |
| 444 | /// match the short markers individually instead. |
| 445 | fn assert_resolves_outside_workspace(err: &str, label: &str) { |
| 446 | assert!( |
| 447 | err.contains("resolves to") |
| 448 | && err.contains("outside the") |
| 449 | && err.contains("sandbox workspace"), |
| 450 | "expected resolves-outside-workspace error for {label}, got: {err}" |
| 451 | ); |
| 452 | } |
| 453 | |
| 454 | /// Regression for the Codex high-severity finding: `validate_sandbox_source_path` |
| 455 | /// is purely lexical, so a sandbox-side symlink that escapes `/sandbox` could |
no outgoing calls
no test coverage detected