diff options
author | Divy Srivastava <dj.srivastava23@gmail.com> | 2022-12-19 10:12:45 -0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-12-19 18:12:45 +0000 |
commit | 5a8adc342bcf01f535079d06778a9f244ba7e96f (patch) | |
tree | ba3f6661df8c82af7c8d37f7258eb27ee9afec56 /test_util | |
parent | 118a35f3bc353cae96bcb29bc96c4f60a7bb1936 (diff) |
chore(test_util): use pty2 instead of pty (#17131)
Fixes https://github.com/denoland/deno/issues/484
Removes dependency on winapi 0.2.x versions.
Diffstat (limited to 'test_util')
-rw-r--r-- | test_util/Cargo.toml | 2 | ||||
-rw-r--r-- | test_util/src/pty.rs | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/test_util/Cargo.toml b/test_util/Cargo.toml index 45fa76881..a2b2626f8 100644 --- a/test_util/Cargo.toml +++ b/test_util/Cargo.toml @@ -40,7 +40,7 @@ tokio-tungstenite.workspace = true url.workspace = true [target.'cfg(unix)'.dependencies] -pty = "0.2.2" +pty2 = "0.1.0" [target.'cfg(windows)'.dependencies] winapi = { workspace = true, features = ["consoleapi", "synchapi", "handleapi", "namedpipeapi", "winbase", "winerror"] } diff --git a/test_util/src/pty.rs b/test_util/src/pty.rs index 83a27926b..4970e08f4 100644 --- a/test_util/src/pty.rs +++ b/test_util/src/pty.rs @@ -24,7 +24,7 @@ pub fn create_pty( cwd: impl AsRef<Path>, env_vars: Option<HashMap<String, String>>, ) -> Box<dyn Pty> { - let fork = pty::fork::Fork::from_ptmx().unwrap(); + let fork = pty2::fork::Fork::from_ptmx().unwrap(); if fork.is_parent().is_ok() { Box::new(unix::UnixPty { fork }) } else { @@ -48,7 +48,7 @@ mod unix { use super::Pty; pub struct UnixPty { - pub fork: pty::fork::Fork, + pub fork: pty2::fork::Fork, } impl Drop for UnixPty { |