Skip to content

Commit

Permalink
Update Karma config
Browse files Browse the repository at this point in the history
  • Loading branch information
mjackson committed Jul 27, 2016
1 parent 56274b8 commit b7152a4
Showing 1 changed file with 6 additions and 15 deletions.
21 changes: 6 additions & 15 deletions karma.conf.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
const path = require('path')
const webpack = require('webpack')
const projectName = require('./package').name

module.exports = (config) => {
const customLaunchers = {
Expand Down Expand Up @@ -91,31 +91,22 @@ module.exports = (config) => {
if (process.env.USE_CLOUD) {
config.browsers = Object.keys(customLaunchers)
config.reporters = [ 'dots' ]
config.concurrency = 2

config.browserDisconnectTimeout = 10000
config.browserDisconnectTolerance = 3
config.browserNoActivityTimeout = 30000
config.captureTimeout = 120000

if (process.env.TRAVIS) {
const buildLabel = 'TRAVIS #' + process.env.TRAVIS_BUILD_NUMBER + ' (' + process.env.TRAVIS_BUILD_ID + ')'

config.browserStack = {
username: process.env.BROWSER_STACK_USERNAME,
accessKey: process.env.BROWSER_STACK_ACCESS_KEY,
pollingTimeout: 10000,
startTunnel: true,
project: 'history',
build: buildLabel,
project: projectName,
build: process.env.TRAVIS_BUILD_NUMBER,
name: process.env.TRAVIS_JOB_NUMBER
}

config.singleRun = true
} else {
config.browserStack = {
username: process.env.BROWSER_STACK_USERNAME,
accessKey: process.env.BROWSER_STACK_ACCESS_KEY,
pollingTimeout: 10000,
startTunnel: true
project: projectName
}
}
}
Expand Down

0 comments on commit b7152a4

Please sign in to comment.