Files
UglifyJS/.github/workflows/ci.yml
2020-04-06 22:16:48 +08:00

39 lines
1.3 KiB
YAML

name: CI
on: [ push, pull_request ]
jobs:
test:
strategy:
matrix:
node: [ "0.10", "0.12", "4", "6", "8", "10", latest ]
os: [ ubuntu-latest, windows-latest ]
script: [ compress, mocha, release/benchmark, release/jetstream ]
name: ${{ matrix.node }} ${{ matrix.os }} ${{ matrix.script }}
runs-on: ${{ matrix.os }}
env:
NODE: ${{ matrix.node }}
TYPE: ${{ matrix.script }}
steps:
- uses: actions/checkout@v1
- uses: actions/cache@v1
with:
path: tmp
key: tmp ${{ matrix.script }}
- name: Perform tests
shell: bash
run: |
git clone --branch v1.5.4 --depth 1 https://github.com/jasongin/nvs.git ~/.nvs
cd ~/.nvs
chmod a+x ./nvs.sh
while !(./nvs.sh --version); do git clean -xdf; done;
while !(./nvs.sh add $NODE); do echo "'nvs add $NODE' failed - retrying..."; done;
./nvs.sh use $NODE
cd -
node --version
npm config set audit false
npm config set optional false
npm config set save false
npm config set update-notifier false
npm --version
while !(npm install); do echo "'npm install' failed - retrying..."; done;
node test/$TYPE