From fe82f6ac7919138e91c2690c5482ff8eb9b58215 Mon Sep 17 00:00:00 2001 From: Rifa Achrinza <25147899+achrinza@users.noreply.github.com> Date: Sun, 21 Nov 2021 15:52:40 +0800 Subject: [PATCH] ci: enable Node.js v17 testing Signed-off-by: Rifa Achrinza <25147899+achrinza@users.noreply.github.com> --- .github/workflows/ci.yaml | 8 ++++++-- .travis.yml | 11 ++++++++++- 2 files changed, 16 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index df1fe987..a50dbbc9 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -18,7 +18,7 @@ jobs: strategy: matrix: os: [ubuntu-latest] - node-version: [10, 12, 14, 16] + node-version: [10, 12, 14, 16, 17] include: - os: macos-latest node-version: 14 @@ -34,8 +34,12 @@ jobs: uses: actions/setup-node@v2 with: node-version: ${{ matrix.node-version }} + - name: Update NPM (Node.js v10) + if: matrix.node-version == 10 + run: npm install --global npm@7 - name: Update NPM - run: npm install --global npm + if: matrix.node-version != 10 + run: npm install --global npm@8 - name: Bootstrap project run: npm ci --ignore-scripts - name: Build project diff --git a/.travis.yml b/.travis.yml index e98235b6..2609d9f9 100644 --- a/.travis.yml +++ b/.travis.yml @@ -5,8 +5,16 @@ arch: - arm64 - ppc64le - s390x +dist: bionic language: node_js -before_install: npm install --global npm +before_install: | + NODEJS_VERSION=$(node --version) + if [ 'v10' = ${NODEJS_VERSION%%.*} ] + then + npm install --global npm@7 + else + npm install --global npm@8 + fi script: - npm run --ignore-scripts build - npm test --ignore-scripts @@ -15,3 +23,4 @@ node_js: - 12 - 14 - 16 + - 17