How to use the kcd-scripts/jest.testURL function in kcd-scripts

To help you get started, we’ve selected a few kcd-scripts examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github paypal / glamorous / jest.config.js View on Github external
const jestConfig = require('kcd-scripts/jest')

function push(prop, ...vals) {
  jestConfig[prop] = jestConfig[prop] || []
  jestConfig[prop].push(...vals)
}

push('coveragePathIgnorePatterns', '/src/.*-entry.js$', '/src/constants.js$')
push('snapshotSerializers', 'enzyme-to-json/serializer', 'jest-glamor-react')
push('setupFiles', '/other/setup-tests.js')

jestConfig.testURL = 'http://localhost'

module.exports = jestConfig