1
0
mirror of https://github.com/vlang/v.git synced 2023-08-10 21:13:21 +03:00

all: support compile time $env('ENV_VAR') (#8456)

This commit is contained in:
Larpon
2021-01-31 18:22:42 +01:00
committed by GitHub
parent 4f4e3e9b61
commit d25825df57
21 changed files with 235 additions and 42 deletions

View File

@ -189,7 +189,8 @@ pub fn (b &Benchmark) step_message_skip(msg string) string {
// total_message returns a string with total summary of the benchmark run.
pub fn (b &Benchmark) total_message(msg string) string {
mut tmsg := '${term.colorize(term.bold, 'Summary:')} '
the_label := term.colorize(term.gray, msg)
mut tmsg := '${term.colorize(term.bold, 'Summary for $the_label:')} '
if b.nfail > 0 {
tmsg += term.colorize(term.bold, term.colorize(term.red, '$b.nfail failed')) + ', '
}
@ -200,7 +201,6 @@ pub fn (b &Benchmark) total_message(msg string) string {
tmsg += term.colorize(term.bold, term.colorize(term.yellow, '$b.nskip skipped')) + ', '
}
tmsg += '$b.ntotal total. ${term.colorize(term.bold, 'Runtime:')} ${b.bench_timer.elapsed().microseconds() / 1000} ms.\n'
tmsg += term.colorize(term.gray, msg)
return tmsg
}