From 45931dc856410c78056cb3a0396724e16eee8d63 Mon Sep 17 00:00:00 2001 From: Joseph Schorr Date: Thu, 30 Nov 2017 10:24:11 -0500 Subject: [PATCH] Add --no-sandbox flag to Karma test --- karma.conf.js | 8 +++++++- package.json | 2 +- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/karma.conf.js b/karma.conf.js index 83c9e9b79..22b081f0c 100644 --- a/karma.conf.js +++ b/karma.conf.js @@ -58,7 +58,13 @@ module.exports = function(config) { colors: true, logLevel: config.LOG_INFO, autoWatch: true, - browsers: ['ChromeHeadless'], + browsers: ['ChromeNoSandbox'], + customLaunchers: { + ChromeNoSandbox: { + base: 'ChromeHeadless', + flags: ['--no-sandbox'] + } + }, singleRun: false, concurrency: Infinity, mime: { diff --git a/package.json b/package.json index fa3c588a8..828195b23 100644 --- a/package.json +++ b/package.json @@ -5,7 +5,7 @@ "version": "1.0.0", "scripts": { "dev": "karma start --browsers ChromeHeadless", - "test": "karma start --single-run --browsers ChromeHeadless", + "test": "karma start --single-run --browsers ChromeNoSandbox", "test:node": "JASMINE_CONFIG_PATH=static/test/jasmine.json jasmine-ts './static/js/**/*.spec.ts'", "e2e": "ts-node ./node_modules/.bin/protractor static/test/protractor.conf.ts", "build": "npm run clean && NODE_ENV=production webpack --progress",