Skip to content

Commit e80e08f

Browse files
committed
fix(tests): upgrade travis config, remove PhantomJS
1 parent 7f214e3 commit e80e08f

File tree

5 files changed

+12
-12
lines changed

5 files changed

+12
-12
lines changed

.travis.yml

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,18 @@
11
sudo: false
2+
dist: bionic
23
language: node_js
4+
node_js:
5+
- '12'
6+
services:
7+
- xvfb
8+
addons:
9+
firefox: latest
10+
chrome: latest
311
cache:
412
directories:
513
- node_modules
614
notifications:
715
email: none
8-
node_js:
9-
- '12'
10-
before_install:
11-
- export DISPLAY=:99.0
12-
- sh -e /etc/init.d/xvfb start
1316
before_script:
1417
- npm prune
1518
script:

gulpfile.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ gulp.task('tdd', function tdd (done) {
4343
var config = testConfig(
4444
{
4545
autoWatch: true,
46-
browsers: ['PhantomJS'],
46+
browsers: ['ChromeHeadless'],
4747
configFile: karmaConfig,
4848
singleRun: false
4949
}
@@ -70,7 +70,7 @@ gulp.task('default', gulp.parallel('complexity', 'test'))
7070

7171
var testConfig = function (options) {
7272
var travisDefaultOptions = {
73-
browsers: ['Firefox'],
73+
browsers: ['FirefoxHeadless', 'ChromeHeadless'],
7474
reporters: ['dots', 'coverage', 'threshold']
7575
}
7676

karma.conf.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,6 @@ module.exports = function (config) {
2626
'karma-jasmine',
2727
'karma-chrome-launcher',
2828
'karma-firefox-launcher',
29-
'karma-phantomjs-launcher',
3029
'karma-coverage',
3130
'karma-threshold-reporter'
3231
],
@@ -85,7 +84,7 @@ module.exports = function (config) {
8584
// - Safari (only Mac)
8685
// - PhantomJS
8786
// - IE (only Windows)
88-
browsers: ['PhantomJS'],
87+
browsers: ['FirefoxHeadless', 'ChromeHeadless'],
8988

9089
// If browser does not capture in given timeout [ms], kill it
9190
captureTimeout: 60000,

package.json

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,11 +34,9 @@
3434
"karma-coverage": "^2.0.2",
3535
"karma-firefox-launcher": "^1.3.0",
3636
"karma-jasmine": "^3.1.1",
37-
"karma-phantomjs-launcher": "^1.0.4",
3837
"karma-threshold-reporter": "^0.1.15",
3938
"karma-webpack": "^4.0.2",
4039
"lodash": "^4.16.4",
41-
"phantomjs-prebuilt": "^2.1.13",
4240
"plato": "^1.7.0",
4341
"run-browser": "^2.0.2",
4442
"semantic-release": "^6.3.0",

test/webpack/karma.conf.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ module.exports = function(config) {
6262

6363
// start these browsers
6464
// available browser launchers: https://npmjs.org/browse/keyword/karma-launcher
65-
browsers: ['PhantomJS'],
65+
browsers: ['FirefoxHeadless', 'ChromeHeadless'],
6666

6767
// Continuous Integration mode
6868
// if true, Karma captures browsers, runs the tests and exits

0 commit comments

Comments
 (0)