From 9814bd9a88353ea2332e199e5f204e215f06c15b Mon Sep 17 00:00:00 2001 From: Refael Ackermann Date: Tue, 6 Nov 2018 16:04:08 -0500 Subject: [PATCH] test: disable color formating for test-internal-errors.js PR-URL: https://github.com/nodejs/node/pull/24204 Fixes: https://github.com/nodejs/node/issues/24193 Refs: https://github.com/nodejs/node/pull/19723 Reviewed-By: Rich Trott Reviewed-By: Ben Noordhuis --- test/parallel/test-internal-errors.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/test/parallel/test-internal-errors.js b/test/parallel/test-internal-errors.js index de5d6ed3b9bb8e..5d28dc411e6069 100644 --- a/test/parallel/test-internal-errors.js +++ b/test/parallel/test-internal-errors.js @@ -8,6 +8,10 @@ const { const assert = require('assert'); const errors = require('internal/errors'); +// Turn off ANSI color formatting for this test file. +const { inspect } = require('util'); +inspect.defaultOptions.colors = false; + errors.E('TEST_ERROR_1', 'Error for testing purposes: %s', Error, TypeError, RangeError); errors.E('TEST_ERROR_2', (a, b) => `${a} ${b}`, Error);