]> source.dussan.org Git - svg.js.git/commitdiff
switch back to firefox for testing
authordotnetCarpenter <jon.ronnenberg@gmail.com>
Sat, 8 Oct 2016 19:28:14 +0000 (17:28 -0200)
committerdotnetCarpenter <jon.ronnenberg@gmail.com>
Sat, 8 Oct 2016 19:28:14 +0000 (17:28 -0200)
.config/chrome_linux.js [deleted file]
.config/karma.conf.js
.gitignore
.travis.yml
package.json

diff --git a/.config/chrome_linux.js b/.config/chrome_linux.js
deleted file mode 100644 (file)
index 5820a19..0000000
+++ /dev/null
@@ -1,42 +0,0 @@
-'use strict'
-
-if(process.platform === 'linux') {
-       const child_process = require('child_process') 
-       const exec = child_process.exec
-       const execSync = bind2(child_process.execSync, { encoding: 'utf8' })//spawnSync
-       const browsers = ['google-chrome', 'chromium-browser']
-
-       const findBrowser = msg => {
-               console.log(msg)
-               const browserString = /\/(.*)$/
-               const browser = msg.match(browserString)
-               console.log(browsers)
-               if(browsers[browser]) browsers[browser] = true
-       }
-
-       const tryCompose = (f, parameter) => {
-               //FIXME:
-               const x = f.splice(0, 1)[0]
-               if(Array.isArray(f) && f.length > 0) return tryCompose(f, parameter)
-               //
-
-               try {
-                       return x(parameter)
-               }
-               catch(e) {
-                       console.warn(e.message)
-               }
-       }
-       
-       tryCompose([findBrowser, execSync], 'which google-chrome')
-       //findBrowser(execSync('which chromium-browser'))
-
-       if(browsers[0]) return
-       if(!browsers[0] && browsers[1]) exec('export CHROME_BIN=chromium-browser')
-       if(browsers.every(b => !b)) console.warn('You need to install either Chrome or Chromium to run the test suite.')
-       
-}
-
-function bind2(f, bound) {
-       return (parameter) => f(parameter, bound)
-}
\ No newline at end of file
index 2a7dae4f2c5d23173a126b0b5e3dfa67b8903b34..ad256e21b88edd4e2da48ec2b22bfd354b3cd668 100644 (file)
@@ -65,16 +65,7 @@ module.exports = function(config) {
 
     // start these browsers
     // available browser launchers: https://npmjs.org/browse/keyword/karma-launcher
-    browsers: ['Chrome'],
-
-
-    customLaunchers: {
-        Chrome_travis_ci: {
-            base: 'Chrome',
-            flags: ['--no-sandbox']
-        }
-    },
-
+    browsers: ['Firefox'],
 
     // Continuous Integration mode
     // if true, Karma captures browsers, runs the tests and exits
@@ -84,8 +75,4 @@ module.exports = function(config) {
     // how many browser should be started simultaneous
     concurrency: Infinity
   })
-
-  if(process.env.TRAVIS){
-    config.browsers = ['Chrome_travis_ci'];
-  }
 }
index 675a80ce85e9981309ea3120651c36b57f1d189d..e27f6184c494e2bdc95363d5baf220a9c9687ad5 100644 (file)
@@ -7,4 +7,5 @@ docs/
 obsolete/
 test/
 src/index.js
-node_modules/
\ No newline at end of file
+node_modules/
+.vscode/
\ No newline at end of file
index 437623d4a8c872e435d29e20081f3dd0b761d7d9..9c2e44a17bb028d9622e3a3c2f7bcb710b1ac880 100644 (file)
@@ -2,10 +2,9 @@ language: node_js
 node_js:
     - "node"
 script: npm test
-#sudo: true
+sudo: true
 before_install:
-    - export CHROME_BIN=chromium-browser
     - export DISPLAY=:99.0
     - sh -e /etc/init.d/xvfb start
-    #- sudo apt-get -qq update
-    #- sudo apt-get install -y chromium-browser
+    - sudo apt-get -qq update
+    - sudo apt-get install -y firefox
index cee6ee668c711a4e5c45c46626af968f3d0d82e2..bfc3052fd1abf39421d6cf8d71fddbfad4055282 100644 (file)
@@ -50,7 +50,6 @@
   "typings": "./svg.js.d.ts",
   "scripts": {
     "build": "gulp",
-    "pretest": "node .config/chrome_linux.js",
     "test": "karma start .config/karma.conf.js --single-run"
   },
   "devDependencies": {
@@ -67,7 +66,6 @@
     "gulp-wrap": "^0.13.0",
     "jasmine-core": "^2.5.2",
     "karma": "^1.3.0",
-    "karma-chrome-launcher": "^2.0.0",
     "karma-firefox-launcher": "^1.0.0",
     "karma-jasmine": "^1.0.2",
     "request": "^2.75.0"