Assert optional args with square brackets [arg...]

This commit is contained in:
Weihang Lo 2022-01-27 19:28:51 +08:00
parent 13a09beccf
commit 11c50416c2
No known key found for this signature in database
GPG Key ID: D7DBF189825E82E7
2 changed files with 2 additions and 2 deletions

View File

@ -1251,7 +1251,7 @@ fn run_multiple_packages() {
cargo().arg("-p").arg("d1").arg("-p").arg("d2")
.with_status(1)
.with_stderr_contains("error: The argument '--package <SPEC>...' was provided more than once, but cannot be used multiple times").run();
.with_stderr_contains("error: The argument '--package [<SPEC>...]' was provided more than once, but cannot be used multiple times").run();
cargo()
.arg("-p")

View File

@ -540,7 +540,7 @@ fn fail_with_multiple_packages() {
.with_status(1)
.with_stderr_contains(
"\
error: The argument '--package <SPEC>...' was provided more than once, \
error: The argument '--package [<SPEC>...]' was provided more than once, \
but cannot be used multiple times
",
)