Skip to content

Commit 8417516

Browse files
committed
add headless chrome for ci tests
1 parent d2288ef commit 8417516

File tree

2 files changed

+8
-1
lines changed

2 files changed

+8
-1
lines changed

karma.conf.js

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,12 @@ module.exports = function (config) {
2626
logLevel: config.LOG_INFO,
2727
autoWatch: true,
2828
browsers: ['Chrome'],
29+
customLaunchers: {
30+
ChromeHeadlessCI: {
31+
base: 'ChromeHeadless',
32+
flags: ['--no-sandbox']
33+
}
34+
},
2935
singleRun: false,
3036
restartOnFileChange: true
3137
});

package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
"build": "ng build",
88
"prod-build": "ng build --prod",
99
"test": "ng test",
10+
"ci-test": "npm run test -- --no-watch --no-progress --browsers=ChromeHeadlessCI",
1011
"lint": "ng lint",
1112
"e2e": "ng e2e"
1213
},
@@ -47,4 +48,4 @@
4748
"tslint": "~6.1.0",
4849
"typescript": "~3.8.3"
4950
}
50-
}
51+
}

0 commit comments

Comments
 (0)