Skip to content

Commit

Permalink
test(complete): Make it order independent
Browse files Browse the repository at this point in the history
  • Loading branch information
epage committed Feb 8, 2024
1 parent b0fea2b commit ea77b98
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions clap_complete/tests/testsuite/bash.rs
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,6 @@ fn complete() {
);
}

// Issue 5313 (https://github.com/clap-rs/clap/issues/5313)
{
use std::fs::File;
use std::path::Path;
Expand All @@ -234,13 +233,11 @@ fn complete() {
File::create(Path::new(testdir_path).join("baz\tqux.txt")).unwrap();

let input = format!(
"exhaustive hint --file {}/\t\t",
"exhaustive hint --file {}/b\t",
testdir_path.to_string_lossy()
);
let expected = r#"%
foo bar.txt baz^Iqux.txt "#;
let actual = runtime.complete(input.as_str(), &term).unwrap();
snapbox::assert_eq(expected, actual);
assert!(!actual.contains("foo"), "Actual output:\n{actual}");
}

let input = "exhaustive hint --other \t";
Expand Down

0 comments on commit ea77b98

Please sign in to comment.