From a527caa24855ec3551281e91c8e1d7909e533254 Mon Sep 17 00:00:00 2001 From: Weihang Lo Date: Thu, 10 Sep 2020 07:57:57 +0800 Subject: [PATCH] test: check stderr containment explicitly --- tests/testsuite/install.rs | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/tests/testsuite/install.rs b/tests/testsuite/install.rs index 053f5603380..8e8ba337f5b 100644 --- a/tests/testsuite/install.rs +++ b/tests/testsuite/install.rs @@ -1636,6 +1636,19 @@ workspace: [..]/foo/Cargo.toml // current working directory. // See https://github.com/rust-lang/cargo/issues/8619 p.cargo("install foo") - .with_stderr_does_not_contain(&stderr) + .with_stderr( + "\ +[UPDATING] `[..]` index +[DOWNLOADING] crates ... +[DOWNLOADED] foo v0.1.0 (registry [..]) +[INSTALLING] foo v0.1.0 +[COMPILING] foo v0.1.0 +[FINISHED] release [optimized] target(s) in [..] +[INSTALLING] [..]foo[EXE] +[INSTALLED] package `foo v0.1.0` (executable `foo[EXE]`) +[WARNING] be sure to add `[..]` to your PATH to be able to run the installed binaries +", + ) .run(); + assert_has_installed_exe(cargo_home(), "foo"); }