Skip to content

Commit d56c7bb

Browse files
m-haishamBenWiederhake
authored andcommitted
kill: add test for vertical --list
1 parent c4c8129 commit d56c7bb

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

tests/by-util/test_kill.rs

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,16 @@ fn test_kill_list_one_signal_from_name() {
9292
.stdout_matches(&Regex::new("\\b9\\b").unwrap());
9393
}
9494

95+
#[test]
96+
fn test_kill_list_all_vertically() {
97+
// Check for a few signals. Do not try to be comprehensive.
98+
let command = new_ucmd!().arg("-l").succeeds();
99+
let signals = command.stdout_str().split('\n').collect::<Vec<&str>>();
100+
assert!(signals.contains(&"KILL"));
101+
assert!(signals.contains(&"TERM"));
102+
assert!(signals.contains(&"HUP"));
103+
}
104+
95105
#[test]
96106
fn test_kill_list_two_signal_from_name() {
97107
new_ucmd!()

0 commit comments

Comments
 (0)