Skip to content

Commit

Permalink
Fix default colors option value
Browse files Browse the repository at this point in the history
  • Loading branch information
ehmicky committed Sep 22, 2019
1 parent 61d1fa5 commit de9f400
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 2 additions & 0 deletions src/colors.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,5 @@ const getLevel = function(colors) {

return Math.max(supportsColor.level, 1)
}

export const DEFAULT_COLORS = Boolean(supportsColor)
4 changes: 2 additions & 2 deletions src/options/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import {
} from '../level.js'
import { validateExitOn } from '../exit.js'
import { defaultLog } from '../log.js'
import { addChalk } from '../colors.js'
import { addChalk, DEFAULT_COLORS } from '../colors.js'

import { applyTesting, getExampleTesting } from './testing.js'

Expand All @@ -34,7 +34,7 @@ const isDefined = function(key, value) {
const DEFAULT_OPTS = {
log: defaultLog,
exitOn: ['uncaughtException'],
colors: true,
colors: DEFAULT_COLORS,
}

// `validate-jest` prints the function body
Expand Down

0 comments on commit de9f400

Please sign in to comment.