]> git.lizzy.rs Git - rust.git/blobdiff - library/test/src/console.rs
Rollup merge of #98301 - ortem:pretty-printers-nonzero, r=wesleywiser
[rust.git] / library / test / src / console.rs
index dc0123cf43266a4446fcde65f4395b2dbdb58173..e9dda98966de3f638044ed1d9e80d1f28aa22253 100644 (file)
@@ -137,7 +137,7 @@ fn current_test_count(&self) -> usize {
 // List the tests to console, and optionally to logfile. Filters are honored.
 pub fn list_tests_console(opts: &TestOpts, tests: Vec<TestDescAndFn>) -> io::Result<()> {
     let mut output = match term::stdout() {
-        None => OutputLocation::Raw(io::stdout()),
+        None => OutputLocation::Raw(io::stdout().lock()),
         Some(t) => OutputLocation::Pretty(t),
     };