Skip to content

Commit 29fece1

Browse files
committed
tail: fix test suspension by redirecting stdin to null
Caused: zsh: suspended (tty input) cargo test
1 parent 3b1957f commit 29fece1

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

tests/by-util/test_tail.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2742,12 +2742,12 @@ fn test_fifo() {
27422742
not(target_os = "openbsd")
27432743
))]
27442744
fn test_fifo_with_pid() {
2745-
use std::process::Command;
2745+
use std::process::{Command, Stdio};
27462746

27472747
let (at, mut ucmd) = at_and_ucmd!();
27482748
at.mkfifo("FIFO");
27492749

2750-
let mut dummy = Command::new("sh").spawn().unwrap();
2750+
let mut dummy = Command::new("sh").stdin(Stdio::null()).spawn().unwrap();
27512751
let pid = dummy.id();
27522752

27532753
let mut child = ucmd

0 commit comments

Comments
 (0)