File tree Expand file tree Collapse file tree 1 file changed +20
-10
lines changed Expand file tree Collapse file tree 1 file changed +20
-10
lines changed Original file line number Diff line number Diff line change 3
3
module . exports = function ( karma ) {
4
4
var args = karma . args || { } ;
5
5
var config = {
6
- browsers : [ 'Firefox' ] ,
7
6
frameworks : [ 'browserify' , 'jasmine' ] ,
8
7
reporters : [ 'progress' , 'kjhtml' ] ,
8
+ browsers : [ 'chrome' , 'firefox' ] ,
9
+
10
+ // Explicitly disable hardware acceleration to make image
11
+ // diff more stable when ran on Travis and dev machine.
12
+ // https://github.com/chartjs/Chart.js/pull/5629
13
+ customLaunchers : {
14
+ chrome : {
15
+ base : 'Chrome' ,
16
+ flags : [
17
+ '--disable-accelerated-2d-canvas'
18
+ ]
19
+ } ,
20
+ firefox : {
21
+ base : 'Firefox' ,
22
+ prefs : {
23
+ 'layers.acceleration.disabled' : true
24
+ }
25
+ }
26
+ } ,
9
27
10
28
preprocessors : {
11
29
'./test/jasmine.index.js' : [ 'browserify' ] ,
@@ -24,15 +42,7 @@ module.exports = function(karma) {
24
42
25
43
// https://swizec.com/blog/how-to-run-javascript-tests-in-chrome-on-travis/swizec/6647
26
44
if ( process . env . TRAVIS ) {
27
- config . browsers . push ( 'chrome_travis_ci' ) ;
28
- config . customLaunchers = {
29
- chrome_travis_ci : {
30
- base : 'Chrome' ,
31
- flags : [ '--no-sandbox' ]
32
- }
33
- } ;
34
- } else {
35
- config . browsers . push ( 'Chrome' ) ;
45
+ config . customLaunchers . chrome . flags . push ( '--no-sandbox' ) ;
36
46
}
37
47
38
48
if ( args . coverage ) {
You can’t perform that action at this time.
0 commit comments