From f2c48cfac533c338f493c4264dc7eebebec1fd07 Mon Sep 17 00:00:00 2001 From: liv <819880950@qq.com> Date: Mon, 22 Apr 2019 18:42:32 +0800 Subject: [PATCH] fix the --nocapture functionality --- src/exercise.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/exercise.rs b/src/exercise.rs index 28ae695..3ba2567 100644 --- a/src/exercise.rs +++ b/src/exercise.rs @@ -38,7 +38,6 @@ impl Exercise { Mode::Test => Command::new("rustc") .args(&["--test", self.path.to_str().unwrap(), "-o", &temp_file()]) .args(RUSTC_COLOR_ARGS) - .args(&["--", "--nocapture"]) .output(), } .expect("Failed to run 'compile' command.") @@ -46,6 +45,7 @@ impl Exercise { pub fn run(&self) -> Output { Command::new(&temp_file()) + .args(&["--", "--nocapture"]) .output() .expect("Failed to run 'run' command") }