Skip to content

Commit 151b196

Browse files
authored
Merge pull request #7828 from cakebaker/mknod_remove_duplicate_test
mknod: remove duplicate test
2 parents 044b33d + f91e321 commit 151b196

File tree

1 file changed

+6
-11
lines changed

1 file changed

+6
-11
lines changed

tests/by-util/test_mknod.rs

Lines changed: 6 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,12 @@ use uutests::util::TestScenario;
1010
use uutests::util_name;
1111

1212
#[test]
13-
fn test_invalid_arg() {
14-
new_ucmd!().arg("--definitely-invalid").fails_with_code(1);
13+
fn test_mknod_invalid_arg() {
14+
new_ucmd!()
15+
.arg("--foo")
16+
.fails_with_code(1)
17+
.no_stdout()
18+
.stderr_contains("unexpected argument '--foo' found");
1519
}
1620

1721
#[test]
@@ -103,15 +107,6 @@ fn test_mknod_character_device_requires_major_and_minor() {
103107
.stderr_contains("invalid value 'c'");
104108
}
105109

106-
#[test]
107-
fn test_mknod_invalid_arg() {
108-
new_ucmd!()
109-
.arg("--foo")
110-
.fails()
111-
.no_stdout()
112-
.stderr_contains("unexpected argument '--foo' found");
113-
}
114-
115110
#[test]
116111
fn test_mknod_invalid_mode() {
117112
new_ucmd!()

0 commit comments

Comments
 (0)