Add test for listing builtin aliases

Added a test that checks that the aliases that currently
are builtin with cargo are indeed being printed with the rest
of the commands when `cargo --list` is called.

Closes #8486
This commit is contained in:
CPerezz 2020-07-24 23:40:49 +02:00
parent 26beca06fc
commit 7b16c7c130

View file

@ -78,6 +78,17 @@ fn list_commands_with_descriptions() {
.run();
}
#[cargo_test]
fn list_aliases_with_descriptions() {
let p = project().build();
p.cargo("--list")
.with_stdout_contains(" b alias: build")
.with_stdout_contains(" c alias: check")
.with_stdout_contains(" r alias: run")
.with_stdout_contains(" t alias: test")
.run();
}
#[cargo_test]
fn list_command_looks_at_path() {
let proj = project().build();