Skip to content

Commit

Permalink
Test bailout when specifying --bin during uninstall of multiple packages
Browse files Browse the repository at this point in the history
  • Loading branch information
nossralf committed Oct 28, 2017
1 parent 6431336 commit cf58031
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions tests/install.rs
Original file line number Diff line number Diff line change
Expand Up @@ -962,3 +962,11 @@ fn test_install_git_cannot_be_a_base_url() {
error: invalid url `github.com:rust-lang-nursery/rustfmt.git`: cannot-be-a-base-URLs are not supported
"));
}

#[test]
fn uninstall_multiple_and_specifying_bin() {
assert_that(cargo_process("uninstall").args(&["foo", "bar"]).arg("--bin").arg("baz"),
execs().with_status(101).with_stderr("\
error: A binary can only be associated with a single installed package, specifying multiple specs with --bin is redundant.
"));
}

0 comments on commit cf58031

Please sign in to comment.