diff options
author | Bartek IwaĆczuk <biwanczuk@gmail.com> | 2022-05-09 13:25:04 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-05-09 13:25:04 +0200 |
commit | d4ad2b809c62b59ee4c3767bf1ff096b30886bdb (patch) | |
tree | ed7b36269d02e859f66272214ecb40164d0e55cc /cli/tools/test.rs | |
parent | 23efc4fcab2ca3b8b47539a7fb1d904efc57eb7c (diff) |
feat(test): repeat test name if there's user output (#14495)
This commit changes test report output to repeat test name
before printing result, but only if there's user output, denoted
by markers.
Diffstat (limited to 'cli/tools/test.rs')
-rw-r--r-- | cli/tools/test.rs | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/cli/tools/test.rs b/cli/tools/test.rs index 1eb36671e..6ed443806 100644 --- a/cli/tools/test.rs +++ b/cli/tools/test.rs @@ -312,6 +312,10 @@ impl PrettyTestReporter { print!("{}", " ".repeat(description.level)); } + if wrote_user_output { + print!("{} ... ", description.name); + } + println!( "{} {}", status, @@ -414,6 +418,10 @@ impl TestReporter for PrettyTestReporter { print!(" "); } + if wrote_user_output { + print!("{} ... ", description.name); + } + let status = match result { TestResult::Ok => colors::green("ok").to_string(), TestResult::Ignored => colors::yellow("ignored").to_string(), |