From dcd0e6e616f174c8bf1a5d177b65d90209117c9f Mon Sep 17 00:00:00 2001 From: Richard Lau Date: Fri, 29 Mar 2019 12:42:11 -0400 Subject: [PATCH 1/2] build: add a `Prepare ccache` job in Travis Combined compile and test of Node.js where lots of files need to be compiled (e.g. after a V8 update) is exceeding the time limit for Travis jobs (50 minutes). Add a job to Travis that compiles Node.js but doesnt run any tests to populate the ccache. Introduce staging and move the `Test Suite` job into a later stage so that it can use the populated ccache. --- .travis.yml | 24 +++++++++++++++++++++--- 1 file changed, 21 insertions(+), 3 deletions(-) diff --git a/.travis.yml b/.travis.yml index 2569b44ec39e83..4ab46e5b1bd0c9 100644 --- a/.travis.yml +++ b/.travis.yml @@ -2,9 +2,13 @@ language: cpp cache: ccache os: linux dist: xenial +stages: + - check + - test matrix: include: - name: "First commit message adheres to guidelines at https://goo.gl/p2fr5Q" + stage: check if: type = pull_request language: node_js node_js: "node" @@ -13,13 +17,27 @@ matrix: bash -x tools/lint-pr-commit-message.sh ${TRAVIS_PULL_REQUEST}; fi - name: "Linter" + stage: check language: node_js node_js: "node" - env: - - NODE=$(which node) script: - - make lint + - NODE=$(which node) make lint + - name: "Prepare ccache" + stage: check + addons: + apt: + sources: + - ubuntu-toolchain-r-test + packages: + - g++-6 + install: + - export CC='ccache gcc-6' CXX='ccache g++-6' JOBS=2 + - ./configure + - make -j2 V= + script: + - true - name: "Test Suite" + stage: test addons: apt: sources: From aa19e0711d738ed2d5f156129bd3276c9d27ce01 Mon Sep 17 00:00:00 2001 From: Richard Lau Date: Thu, 28 Mar 2019 21:07:19 +0000 Subject: [PATCH 2/2] build: fix skipping of flaky tests on Travis `PARALLEL_ARGS` is overwritten in the Makefile if `JOBS` is set. Use `CI_JS_SUITES` instead. --- .travis.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 4ab46e5b1bd0c9..87f4c38687be86 100644 --- a/.travis.yml +++ b/.travis.yml @@ -49,4 +49,4 @@ matrix: - ./configure - make -j2 V= script: - - PARALLEL_ARGS='--flaky-tests=skip' make -j1 test + - CI_JS_SUITES='--flaky-tests=skip default' make -j1 test