From 3c0f2cfb05c94adb164ac863a96eb2cf09e8110a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Go=C5=82=C4=99biowski-Owczarek?= Date: Wed, 3 Jan 2018 09:41:46 +0100 Subject: [PATCH] Build: Only run browser tests in one Node version on Travis Ref gh-3744 Closes gh-3894 --- .travis.yml | 9 +++++++++ package.json | 6 ++++-- 2 files changed, 13 insertions(+), 2 deletions(-) diff --git a/.travis.yml b/.travis.yml index 317c3a854..4fa82ae7a 100644 --- a/.travis.yml +++ b/.travis.yml @@ -7,3 +7,12 @@ node_js: - "9" addons: chrome: stable +env: + - NPM_SCRIPT=test:browserless +matrix: + include: + # Run browser tests only on one Node.js version to save time. + - node_js: "8" + env: NPM_SCRIPT=test:browser +script: + - npm run $NPM_SCRIPT diff --git a/package.json b/package.json index ba9883826..53ea4f7eb 100644 --- a/package.json +++ b/package.json @@ -68,8 +68,10 @@ "scripts": { "build": "npm install && grunt", "start": "grunt watch", - "test": "grunt && grunt test:slow karma:main", - "jenkins": "grunt && grunt test:slow", + "test:browserless": "grunt && grunt test:slow", + "test:browser": "grunt && grunt karma:main", + "test": "grunt && grunt test:slow && grunt karma:main", + "jenkins": "npm run test:browserless", "precommit": "grunt lint:newer qunit_fixture", "commitmsg": "node node_modules/commitplease" },