Skip to content

Commit 90dc0b0

Browse files
committed
Lock stdout once when listing tests
1 parent d68e7eb commit 90dc0b0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Diff for: library/test/src/console.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,7 @@ impl ConsoleTestState {
137137
// List the tests to console, and optionally to logfile. Filters are honored.
138138
pub fn list_tests_console(opts: &TestOpts, tests: Vec<TestDescAndFn>) -> io::Result<()> {
139139
let mut output = match term::stdout() {
140-
None => OutputLocation::Raw(io::stdout()),
140+
None => OutputLocation::Raw(io::stdout().lock()),
141141
Some(t) => OutputLocation::Pretty(t),
142142
};
143143

0 commit comments

Comments
 (0)