diff options
Diffstat (limited to 'test')
-rw-r--r-- | test/sys/test_termios.rs | 6 | ||||
-rw-r--r-- | test/test_pty.rs | 2 |
2 files changed, 4 insertions, 4 deletions
diff --git a/test/sys/test_termios.rs b/test/sys/test_termios.rs index 4fa6df9b..00aeb2fc 100644 --- a/test/sys/test_termios.rs +++ b/test/sys/test_termios.rs @@ -22,7 +22,7 @@ fn test_tcgetattr_pty() { let _m = crate::PTSNAME_MTX.lock().expect("Mutex got poisoned by another test"); let pty = openpty(None, None).expect("openpty failed"); - assert!(termios::tcgetattr(pty.master).is_ok()); + assert!(termios::tcgetattr(pty.slave).is_ok()); close(pty.master).expect("closing the master failed"); close(pty.slave).expect("closing the slave failed"); } @@ -53,7 +53,7 @@ fn test_output_flags() { let pty = openpty(None, None).expect("openpty failed"); assert!(pty.master > 0); assert!(pty.slave > 0); - let termios = tcgetattr(pty.master).expect("tcgetattr failed"); + let termios = tcgetattr(pty.slave).expect("tcgetattr failed"); close(pty.master).unwrap(); close(pty.slave).unwrap(); termios @@ -95,7 +95,7 @@ fn test_local_flags() { let pty = openpty(None, None).unwrap(); assert!(pty.master > 0); assert!(pty.slave > 0); - let termios = tcgetattr(pty.master).unwrap(); + let termios = tcgetattr(pty.slave).unwrap(); close(pty.master).unwrap(); close(pty.slave).unwrap(); termios diff --git a/test/test_pty.rs b/test/test_pty.rs index 1e085877..ab347bb0 100644 --- a/test/test_pty.rs +++ b/test/test_pty.rs @@ -205,7 +205,7 @@ fn test_openpty_with_termios() { let pty = openpty(None, None).unwrap(); assert!(pty.master > 0); assert!(pty.slave > 0); - let termios = tcgetattr(pty.master).unwrap(); + let termios = tcgetattr(pty.slave).unwrap(); close(pty.master).unwrap(); close(pty.slave).unwrap(); termios |