From a01b05e44e46b382a197990918a3532cc9d6e852 Mon Sep 17 00:00:00 2001 From: Michael Brade Date: Thu, 14 May 2020 01:01:18 +0200 Subject: [PATCH] diffs: switch to using background color instead of visible spaces --- lib/reporters/base.js | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/lib/reporters/base.js b/lib/reporters/base.js index c6b5312491..78858c9e4a 100644 --- a/lib/reporters/base.js +++ b/lib/reporters/base.js @@ -68,8 +68,8 @@ exports.colors = { green: 32, light: 90, 'diff gutter': 90, - 'diff added': 32, - 'diff removed': 31 + 'diff added': '30;42', + 'diff removed': '30;41' }; /** @@ -390,10 +390,6 @@ function pad(str, len) { * @return {string} Diff */ function inlineDiff(actual, expected) { - // make spaces visible by replacing them with U+2423 (open box char) - actual = actual.replace(/ /gi, '\u2423'); - expected = expected.replace(/ /gi, '\u2423'); - var msg = errorDiff(actual, expected); // linenos