From 175d7f65e86175e955d76972f906425555e34e87 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Benoit?= Date: Fri, 4 Oct 2024 22:12:34 +0200 Subject: [PATCH] fix: format iters/s warnings properly MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Jérôme Benoit --- src/reporter/terminal/table.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/reporter/terminal/table.js b/src/reporter/terminal/table.js index 20adb60..bfc719a 100644 --- a/src/reporter/terminal/table.js +++ b/src/reporter/terminal/table.js @@ -168,7 +168,7 @@ export function warning( benchmark.stats.throughput.rmoe > highRelativeMarginOfError ) { warnings.push( - `${bold(colors, yellow(colors, 'Warning'))}: ${bold(colors, cyan(colors, benchmark.name))} has a high latency throughput margin of error: ${red(colors, errorMargin(benchmark.stats.throughput.rmoe))}` + `${bold(colors, yellow(colors, 'Warning'))}: ${bold(colors, cyan(colors, benchmark.name))} has a high latency throughput margin of error: ${red(colors, itersPerSecond(benchmark.stats.throughput.rmoe))}` ) } if (latency && benchmark.stats.latency.mad > 0) { @@ -178,7 +178,7 @@ export function warning( } if (throughput && benchmark.stats.throughput.mad > 0) { warnings.push( - `${bold(colors, yellow(colors, 'Warning'))}: ${bold(colors, cyan(colors, benchmark.name))} has a non zero throughput median absolute deviation: ${red(colors, duration(benchmark.stats.throughput.mad))}` + `${bold(colors, yellow(colors, 'Warning'))}: ${bold(colors, cyan(colors, benchmark.name))} has a non zero throughput median absolute deviation: ${red(colors, itersPerSecond(benchmark.stats.throughput.mad))}` ) } }