Skip to content

Commit

Permalink
test_dircolors: add test_extra_operand
Browse files Browse the repository at this point in the history
  • Loading branch information
jhscheer committed Jun 5, 2022
1 parent f1b38e9 commit 18bfc03
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions tests/by-util/test_dircolors.rs
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,15 @@ fn test_stdin() {
.no_stderr();
}

#[test]
fn test_extra_operand() {
new_ucmd!()
.args(&["-c", "file1", "file2"])
.fails()
.stderr_contains("dircolors: extra operand 'file2'\n")
.no_stdout();
}

fn test_helper(file_name: &str, term: &str) {
new_ucmd!()
.env("TERM", term)
Expand Down

0 comments on commit 18bfc03

Please sign in to comment.