diff options
| author | Ogulcan Celik <ogulcancelik@gmail.com> | 2026-05-17 01:41:17 +0300 |
|---|---|---|
| committer | Ogulcan Celik <ogulcancelik@gmail.com> | 2026-05-17 01:41:17 +0300 |
| commit | 3ecacfddae86d603bfd0d1a0c01602b1d34b1df3 (patch) | |
| tree | 277941c065295af2bd161c6be6fd7a2555c1f060 /src/workspace.rs | |
| parent | a36da363f14639085bec91d7a378d6c2eeaa6c58 (diff) | |
feat: add direct terminal attach stream
Diffstat (limited to 'src/workspace.rs')
| -rw-r--r-- | src/workspace.rs | 20 |
1 files changed, 15 insertions, 5 deletions
diff --git a/src/workspace.rs b/src/workspace.rs index 553206c4..1d8842c8 100644 --- a/src/workspace.rs +++ b/src/workspace.rs @@ -720,15 +720,25 @@ mod tests { #[test] fn workspace_identity_uses_identity_cwd() { + let root = std::env::temp_dir().join(format!( + "herdr-workspace-identity-{}-{}", + std::process::id(), + std::time::SystemTime::now() + .duration_since(std::time::UNIX_EPOCH) + .unwrap() + .as_nanos() + )); + let identity_cwd = root.join("pion"); + std::fs::create_dir_all(identity_cwd.join(".git")).unwrap(); + let mut ws = Workspace::test_new("ignored"); ws.custom_name = None; - ws.identity_cwd = PathBuf::from("/herdr-test/pion"); + ws.identity_cwd = identity_cwd.clone(); assert_eq!(ws.display_name(), "pion"); - assert_eq!( - ws.resolved_identity_cwd(), - Some(PathBuf::from("/herdr-test/pion")) - ); + assert_eq!(ws.resolved_identity_cwd(), Some(identity_cwd)); + + std::fs::remove_dir_all(root).unwrap(); } #[test] |
