From b255d91e6d2a668480f61f7be2d30879a189a314 Mon Sep 17 00:00:00 2001 From: Ade Attwood Date: Thu, 6 Oct 2022 07:41:44 +0100 Subject: [PATCH] test: improve style of the test output Add more space around the text, also make the text a readable color on dark backgrounds. --- scripts/test.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/test.lua b/scripts/test.lua index 2ee1bcc..2a31937 100644 --- a/scripts/test.lua +++ b/scripts/test.lua @@ -57,14 +57,14 @@ _G.it = function(name, callback) call_hook "after_each" - local prefix = "\x1B[42mPASS" + local prefix = "\x1B[42m\x1B[30m PASS " global_context.total = global_context.total + 1 if status then global_context.pass = global_context.pass + 1 else global_context.fail = global_context.fail + 1 - prefix = "\x1B[41mFAIL" + prefix = "\x1B[41m\x1B[30m FAIL " end print(string.format("%s\x1B[0m %s - %s (%.3f ms)", prefix, global_context.current_test_name, name, elapsed))