Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

report status to stderr instead of stdout #2693

Merged
merged 26 commits into from
May 20, 2016
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/cargo/core/shell.rs
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ impl MultiShell {
{
match self.verbosity {
Quiet => Ok(()),
_ => self.out().say_status(status, message, GREEN, true)
_ => self.err().say_status(status, message, GREEN, true)
}
}

Expand Down
5 changes: 5 additions & 0 deletions tests/test_bad_config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,7 @@ test!(bad3 {
"#);
assert_that(foo.cargo_process("publish").arg("-v"),
execs().with_status(101).with_stderr("\
[UPDATING] registry `https://[..]`
[ERROR] invalid configuration for key `http.proxy`
expected a string, but found a boolean in [..]config
"));
Expand Down Expand Up @@ -232,6 +233,7 @@ test!(bad_git_dependency {

assert_that(foo.cargo_process("build").arg("-v"),
execs().with_status(101).with_stderr("\
[UPDATING] git repository `file:///`
[ERROR] Unable to update file:///

Caused by:
Expand All @@ -258,6 +260,8 @@ test!(bad_crate_type {
assert_that(foo.cargo_process("build").arg("-v"),
execs().with_status(0).with_stderr("\
warning: crate-type \"bad_type\" was not one of lib|rlib|dylib|staticlib
[COMPILING] foo v0.0.0 (file:///[..])
[RUNNING] `rustc [..] --crate-type rlib [..]`
"));
});

Expand Down Expand Up @@ -430,6 +434,7 @@ test!(unused_keys {
assert_that(foo.cargo_process("build"),
execs().with_status(0).with_stderr("\
warning: unused manifest key: target.foo.bar
[COMPILING] foo v0.1.0 (file:///[..])
"));
});

Expand Down
Loading