Reduce the travis load with build stages

This commit is contained in:
Tobias Koppers 2018-05-17 18:14:34 +02:00
parent 18d1df9772
commit 7453db9ddd
3 changed files with 38 additions and 8 deletions

View File

@ -10,28 +10,41 @@ branches:
cache:
yarn: true
stages:
- basic
- advanced
- versions
matrix:
include:
- os: linux
node_js: "10"
env: NO_WATCH_TESTS=1 JEST=--maxWorkers=2 JOB_PART=basic
stage: basic
- os: linux
node_js: "10"
env: NO_WATCH_TESTS=1 JOB_PART=lint
stage: advanced
- os: linux
node_js: "10"
env: NO_WATCH_TESTS=1 JEST=--maxWorkers=2 JOB_PART=integration
- os: linux
node_js: "8"
env: NO_WATCH_TESTS=1 JEST=--maxWorkers=2 JOB_PART=integration
stage: advanced
- os: linux
node_js: "10"
env: NO_WATCH_TESTS=1 JOB_PART=unit
- os: linux
node_js: "6"
env: NO_WATCH_TESTS=1 JEST=--maxWorkers=2 JOB_PART=integration
stage: advanced
- os: osx
node_js: "10"
env: NO_WATCH_TESTS=1 JEST=--maxWorkers=2 JOB_PART=integration
allow_failures:
- os: osx
stage: versions
- os: linux
node_js: "8"
env: NO_WATCH_TESTS=1 JEST=--maxWorkers=2 JOB_PART=integration
stage: versions
- os: linux
node_js: "6"
env: NO_WATCH_TESTS=1 JEST=--maxWorkers=2 JOB_PART=integration
stage: versions
fast_finish: true
install:

View File

@ -7,6 +7,9 @@ coverage:
status:
project:
default: off
basic:
flags: basic
target: auto
integration:
flags: integration
target: auto
@ -15,6 +18,10 @@ coverage:
target: 0%
patch:
default: off
integration:
flags: integration
target: 90%
base: pr
integration:
flags: integration
target: 90%
@ -25,6 +32,9 @@ coverage:
base: pr
changes:
default: off
basic:
flags: basic
target: 0%
integration:
flags: integration
target: 0%
@ -32,3 +42,8 @@ coverage:
flags: unit
target: 0%
comment: off
flags:
basic:
joined: false
unit:
joined: false

View File

@ -99,8 +99,10 @@
"setup": "node ./setup/setup.js",
"test": "node --max-old-space-size=4096 --trace-deprecation node_modules/jest-cli/bin/jest",
"test:integration": "node --max-old-space-size=4096 --trace-deprecation node_modules/jest-cli/bin/jest --testMatch \"<rootDir>/test/*.test.js\"",
"test:basic": "node --max-old-space-size=4096 --trace-deprecation node_modules/jest-cli/bin/jest --testMatch \"<rootDir>/test/{TestCasesNormal,ConfigTestCases}.test.js\"",
"test:unit": "node --max-old-space-size=4096 --trace-deprecation node_modules/jest-cli/bin/jest --testMatch \"<rootDir>/test/*.unittest.js\"",
"travis:integration": "yarn cover:init && yarn cover:integration --ci $JEST && yarn cover:report-min",
"travis:basic": "yarn test:basic --ci $JEST",
"travis:unit": "yarn cover:init && yarn cover:unit --ci",
"travis:lint": "yarn lint",
"travis:benchmark": "yarn benchmark --ci",