Sha256: 0eb1736f3cf408265e91790e4fb519db2c49ee50e79538b61344064670678fa7

Contents?: true

Size: 1.04 KB

Versions: 45

Compression:

Stored size: 1.04 KB

Contents

require('@babel/register')({
  rootMode: 'upward'
})

const puppeteer = require('puppeteer')
const webpackConfig = require('../webpack.config.mjs')

// Use Chrome headless
process.env.CHROME_BIN = puppeteer.executablePath()

module.exports = function (config) {
  config.set({
    basePath: '../',
    frameworks: ['mocha', 'webpack'],
    reporters: ['mocha'],

    browsers: ['ChromeHeadless'],

    files: [
      'test/functional/**/*.js'
    ],

    preprocessors: {
      'test/**/*.js': ['webpack'],
      'src/**/*.js': ['webpack'],
      '**/*.js': ['sourcemap']
    },

    webpack: {
      // Use standalone webpack config [0] rather
      // than Preact [1] or React [2] configs
      ...webpackConfig.default[0],

      // Use Karma managed test entry points
      entry: undefined,

      // Use Karma default `os.tmpdir()` output
      output: undefined,

      // Suppress webpack performance warnings due to
      // Karma chunked output and inline source maps
      performance: { hints: false },
      stats: { preset: 'errors-only' }
    }
  })
}

Version data entries

45 entries across 45 versions & 1 rubygems

Version Path
govuk_publishing_components-44.2.0 node_modules/accessible-autocomplete/test/karma.config.js
govuk_publishing_components-44.1.0 node_modules/accessible-autocomplete/test/karma.config.js
govuk_publishing_components-44.0.0 node_modules/accessible-autocomplete/test/karma.config.js
govuk_publishing_components-43.5.0 node_modules/accessible-autocomplete/test/karma.config.js
govuk_publishing_components-43.4.1 node_modules/accessible-autocomplete/test/karma.config.js