Skip to content

Commit d61c703

Browse files
committed
test_runner: color errors only when colors are avilable
1 parent a00137e commit d61c703

File tree

1 file changed

+2
-2
lines changed
  • lib/internal/test_runner/reporter

1 file changed

+2
-2
lines changed

lib/internal/test_runner/reporter/spec.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,10 @@ const {
1414
const assert = require('assert');
1515
const Transform = require('internal/streams/transform');
1616
const { inspectWithNoCustomRetry } = require('internal/errors');
17-
const { green, blue, red, white, gray } = require('internal/util/colors');
17+
const { green, blue, red, white, gray, hasColors } = require('internal/util/colors');
1818
const { getCoverageReport } = require('internal/test_runner/utils');
1919

20-
const inspectOptions = { __proto__: null, colors: true, breakLength: Infinity };
20+
const inspectOptions = { __proto__: null, colors: hasColors, breakLength: Infinity };
2121

2222
const colors = {
2323
'__proto__': null,

0 commit comments

Comments
 (0)