CI: keep test vectors byte-exact on Windows, short agent paths on macOS
Windows checkouts converted LF vectors to CRLF; SystemTime there has 100 ns resolution. macOS's long $TMPDIR pushed the agent socket past SUN_LEN.
This commit is contained in:
+7
-1
@@ -24,7 +24,13 @@ struct Env {
|
||||
|
||||
impl Env {
|
||||
fn new(tag: &str) -> Env {
|
||||
let dir = std::env::temp_dir().join(format!(
|
||||
// Not temp_dir(): macOS's long $TMPDIR pushes the agent socket path
|
||||
// past SUN_LEN.
|
||||
#[cfg(unix)]
|
||||
let base = PathBuf::from("/tmp");
|
||||
#[cfg(not(unix))]
|
||||
let base = std::env::temp_dir();
|
||||
let dir = base.join(format!(
|
||||
"vault-cli-{tag}-{}-{}",
|
||||
std::process::id(),
|
||||
std::time::SystemTime::now()
|
||||
|
||||
Reference in New Issue
Block a user