assert_that(p.cargo_process("build"),
execs()
- .with_stdout(&format!("[COMPILING] bar v0.5.0 ({}/bar)\n\
+ .with_stderr(&format!("[COMPILING] bar v0.5.0 ({}/bar)\n\
[COMPILING] foo v0.5.0 ({})\n",
p.url(),
p.url()))
assert_that(project.cargo_process("build"),
execs()
- .with_stdout(&format!("[UPDATING] git repository `{}`\n\
+ .with_stderr(&format!("[UPDATING] git repository `{}`\n\
[COMPILING] dep1 v0.5.0 ({}#[..])\n\
[COMPILING] foo v0.5.0 ({})\n",
path2url(git_root.clone()),
assert_that(project.cargo_process("build"),
execs()
- .with_stdout(&format!("[UPDATING] git repository `{}`\n\
+ .with_stderr(&format!("[UPDATING] git repository `{}`\n\
[COMPILING] dep1 v0.5.0 ({}?branch=branchy#[..])\n\
[COMPILING] foo v0.5.0 ({})\n",
path2url(git_root.clone()),
assert_that(project.cargo_process("build"),
execs()
- .with_stdout(&format!("[UPDATING] git repository `{}`\n\
+ .with_stderr(&format!("[UPDATING] git repository `{}`\n\
[COMPILING] dep1 v0.5.0 ({}?tag=v0.1.0#[..])\n\
[COMPILING] foo v0.5.0 ({})\n",
path2url(git_root.clone()),
// First time around we should compile both foo and bar
assert_that(p.cargo_process("build"),
- execs().with_stdout(&format!("[UPDATING] git repository `{}`\n\
+ execs().with_stderr(&format!("[UPDATING] git repository `{}`\n\
[COMPILING] bar v0.5.0 ({}#[..])\n\
[COMPILING] foo v0.5.0 ({})\n",
git_project.url(),
execs().with_stdout(""));
assert_that(p.cargo("update"),
- execs().with_stdout(&format!("[UPDATING] git repository `{}`",
+ execs().with_stderr(&format!("[UPDATING] git repository `{}`",
git_project.url())));
assert_that(p.cargo("build"),
// Update the dependency and carry on!
assert_that(p.cargo("update"),
- execs().with_stdout(&format!("[UPDATING] git repository `{}`\n\
+ execs().with_stderr(&format!("[UPDATING] git repository `{}`\n\
[UPDATING] bar v0.5.0 ([..]) -> #[..]\n\
",
git_project.url())));
println!("going for the last compile");
assert_that(p.cargo("build"),
- execs().with_stdout(&format!("[COMPILING] bar v0.5.0 ({}#[..])\n\
+ execs().with_stderr(&format!("[COMPILING] bar v0.5.0 ({}#[..])\n\
[COMPILING] foo v0.5.0 ({})\n",
git_project.url(),
p.url())));
.arg("-p").arg("foo"),
execs().with_stdout(""));
assert_that(p.cargo("build"),
- execs().with_stdout(&format!("[COMPILING] foo v0.5.0 ({})\n",
+ execs().with_stderr(&format!("[COMPILING] foo v0.5.0 ({})\n",
p.url())));
});
assert_that(p.cargo("update")
.arg("-p").arg("dep1")
.arg("--aggressive"),
- execs().with_stdout(&format!("[UPDATING] git repository `{}`\n\
+ execs().with_stderr(&format!("[UPDATING] git repository `{}`\n\
[UPDATING] bar v0.5.0 ([..]) -> #[..]\n\
", git_project.url())));
// We should be able to update transitive deps
assert_that(p.cargo("update").arg("-p").arg("bar"),
- execs().with_stdout(&format!("[UPDATING] git repository `{}`",
+ execs().with_stderr(&format!("[UPDATING] git repository `{}`",
git_project.url())));
});
assert_that(project.cargo_process("build"),
execs()
- .with_stdout(&format!("[UPDATING] git repository `[..]`\n\
+ .with_stderr(&format!("[UPDATING] git repository `[..]`\n\
[UPDATING] git repository `[..]`\n\
[COMPILING] [..] v0.5.0 ([..])\n\
[COMPILING] [..] v0.5.0 ([..])\n\
assert_that(project.cargo("update")
.arg("-p").arg("dep1"),
execs()
- .with_stdout(&format!("[UPDATING] git repository `{}`\n\
+ .with_stderr(&format!("[UPDATING] git repository `{}`\n\
[UPDATING] dep1 v0.5.0 ([..]) -> #[..]\n\
", git1.url()))
.with_stderr(""));
assert_that(project.cargo("update").arg("-v"),
execs()
.with_stderr("")
- .with_stdout(&format!("[UPDATING] git repository `{}`\n\
+ .with_stderr(&format!("[UPDATING] git repository `{}`\n\
[UPDATING] dep1 v0.5.0 ([..]) -> #[..]\n\
", git_project.url())));
assert_that(p.cargo_process("build"),
execs()
- .with_stdout(&format!("[UPDATING] git repository `{}`\n\
+ .with_stderr(&format!("[UPDATING] git repository `{}`\n\
[COMPILING] bar v0.5.0 ({}#[..])\n\
[COMPILING] foo v0.5.0 ({})\n",
bar.url(),
assert_that(p.cargo_process("build"),
execs().with_status(0)
- .with_stdout(&format!("[COMPILING] baz v0.5.0 ({}/bar/baz)\n\
+ .with_stderr(&format!("[COMPILING] baz v0.5.0 ({}/bar/baz)\n\
[COMPILING] bar v0.5.0 ({}/bar)\n\
[COMPILING] foo v0.5.0 ({})\n",
p.url(),
println!("building baz");
assert_that(p.cargo("build").arg("-p").arg("baz"),
execs().with_status(0)
- .with_stdout(&format!("[COMPILING] baz v0.5.0 ({}/bar/baz)\n",
+ .with_stderr(&format!("[COMPILING] baz v0.5.0 ({}/bar/baz)\n",
p.url())));
println!("building foo");
assert_that(p.cargo("build")
.arg("-p").arg("foo"),
execs().with_status(0)
- .with_stdout(&format!("[COMPILING] bar v0.5.0 ({}/bar)\n\
+ .with_stderr(&format!("[COMPILING] bar v0.5.0 ({}/bar)\n\
[COMPILING] foo v0.5.0 ({})\n",
p.url(),
p.url())));
"#);
assert_that(p.cargo_process("build"),
- execs().with_stdout(&format!("[COMPILING] bar v0.5.0 ({}/bar)\n\
+ execs().with_stderr(&format!("[COMPILING] bar v0.5.0 ({}/bar)\n\
[COMPILING] foo v0.5.0 ({})\n",
p.url(),
p.url())));
"#);
// First time around we should compile both foo and bar
assert_that(p.cargo_process("build"),
- execs().with_stdout(&format!("[COMPILING] bar v0.5.0 ({}/bar)\n\
+ execs().with_stderr(&format!("[COMPILING] bar v0.5.0 ({}/bar)\n\
[COMPILING] foo v0.5.0 ({})\n",
p.url(),
p.url())));
p.build(); // rebuild the files (rewriting them in the process)
assert_that(p.cargo("build"),
- execs().with_stdout(&format!("[COMPILING] bar v0.5.0 ({}/bar)\n\
+ execs().with_stderr(&format!("[COMPILING] bar v0.5.0 ({}/bar)\n\
[COMPILING] foo v0.5.0 ({})\n",
p.url(),
p.url())));
pub fn baz() {}
"#);
assert_that(p.cargo_process("build"),
- execs().with_stdout(&format!("[COMPILING] baz v0.5.0 ({}/baz)\n\
+ execs().with_stderr(&format!("[COMPILING] baz v0.5.0 ({}/baz)\n\
[COMPILING] bar v0.5.0 ({}/bar)\n\
[COMPILING] foo v0.5.0 ({})\n",
p.url(),
pub fn baz() { println!("hello!"); }
"#).unwrap();
assert_that(p.cargo("build"),
- execs().with_stdout(&format!("[COMPILING] baz v0.5.0 ({}/baz)\n\
+ execs().with_stderr(&format!("[COMPILING] baz v0.5.0 ({}/baz)\n\
[COMPILING] bar v0.5.0 ({}/bar)\n\
[COMPILING] foo v0.5.0 ({})\n",
p.url(),
pub fn bar() { println!("hello!"); baz::baz(); }
"#).unwrap();
assert_that(p.cargo("build"),
- execs().with_stdout(&format!("[COMPILING] bar v0.5.0 ({}/bar)\n\
+ execs().with_stderr(&format!("[COMPILING] bar v0.5.0 ({}/bar)\n\
[COMPILING] foo v0.5.0 ({})\n",
p.url(),
p.url())));
pub fn baz() {}
"#);
assert_that(p.cargo_process("build"),
- execs().with_stdout(&format!("[COMPILING] baz v0.5.0 ({}/baz)\n\
+ execs().with_stderr(&format!("[COMPILING] baz v0.5.0 ({}/baz)\n\
[COMPILING] bar v0.5.0 ({}/bar)\n\
[COMPILING] foo v0.5.0 ({})\n",
p.url(),
let bar = p.url();
assert_that(p.cargo_process("build"),
- execs().with_stdout(&format!("[COMPILING] bar v0.5.0 ({}/src/bar)\n\
+ execs().with_stderr(&format!("[COMPILING] bar v0.5.0 ({}/src/bar)\n\
[COMPILING] foo v0.5.0 ({})\n",
bar,
p.url())));
// This shouldn't recompile `bar`
assert_that(p.cargo("build"),
- execs().with_stdout(&format!("[COMPILING] foo v0.5.0 ({})\n",
+ execs().with_stderr(&format!("[COMPILING] foo v0.5.0 ({})\n",
p.url())));
});
p.root().join("bar").move_into_the_past().unwrap();
assert_that(p.cargo("build"),
- execs().with_stdout(&format!("[COMPILING] bar v0.5.0 ({}/bar)\n\
+ execs().with_stderr(&format!("[COMPILING] bar v0.5.0 ({}/bar)\n\
[COMPILING] foo v0.5.0 ({})\n",
p.url(),
p.url())));
}
assert_that(p.cargo("build"),
- execs().with_stdout(&format!("[COMPILING] bar v0.5.0 ({}/bar)\n\
+ execs().with_stderr(&format!("[COMPILING] bar v0.5.0 ({}/bar)\n\
[COMPILING] foo v0.5.0 ({})\n",
p.url(),
p.url())));
assert_that(p.cargo("build")
.env("FOO", "bar"),
execs().with_status(0)
- .with_stdout(&format!("[COMPILING] foo v0.5.0 ({})\n",
+ .with_stderr(&format!("[COMPILING] foo v0.5.0 ({})\n",
p.url())));
assert_that(p.cargo("test"),