From 292b165abeb92b48b8c9c4ca26769d5c4ceda471 Mon Sep 17 00:00:00 2001 From: Delyan Angelov Date: Wed, 8 Apr 2020 18:49:00 +0300 Subject: [PATCH] tests: use the yellow color for 'the ok, fail, skip, total' line too --- vlib/benchmark/benchmark.v | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/vlib/benchmark/benchmark.v b/vlib/benchmark/benchmark.v index 524485b765..9d8bf4795e 100644 --- a/vlib/benchmark/benchmark.v +++ b/vlib/benchmark/benchmark.v @@ -182,7 +182,7 @@ pub fn (b &Benchmark) step_message_skip(msg string) string { } pub fn (b &Benchmark) total_message(msg string) string { - mut tmsg := '${msg}\n ok, fail, skip, total = ' + term.ok_message('${b.nok:5d}') + ', ' + if b.nfail > 0 { term.fail_message('${b.nfail:5d}') } else { '${b.nfail:5d}' } + ', ' + '${b.nskip:5d}'+ ', ' + '${b.ntotal:5d}' + mut tmsg := '${msg}\n ok, fail, skip, total = ' + term.ok_message('${b.nok:5d}') + ', ' + if b.nfail > 0 { term.red('${b.nfail:5d}') } else { '${b.nfail:5d}' } + ', ' + if b.nskip > 0 { term.bright_yellow('${b.nskip:5d}') } else { '${b.nskip:5d}' } + ', ' + '${b.ntotal:5d}' if b.verbose { tmsg = '<=== total time spent $tmsg' }