diff options
Diffstat (limited to '.github/workflows/ci.yml')
-rw-r--r-- | .github/workflows/ci.yml | 55 |
1 files changed, 55 insertions, 0 deletions
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..4f2856a --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,55 @@ +name: CI + +on: + push: + branches: + - main + pull_request: + branches: + - main + +jobs: + test: + runs-on: ubuntu-latest + strategy: + fail-fast: false + matrix: + node-version: + - '4.x' + - '6.x' + - '7.x' + - '8.x' + - '9.x' + - '10.0' + - '10.x' + - '11.0' + - '11.x' + - '12.0' + - '12.x' + - '13.0' + - '13.x' + - '14.0' + - '14.x' + - '15.0' + - '15.x' + - '16.0' + - '16.x' + steps: + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v2 + with: + node-version: ${{ matrix.node-version }} + - uses: actions/checkout@v2 + - if: ${{ matrix.node-version == '4.x' || matrix.node-version == '6.0' }} + run: npm install mocha@5.0.0 eslint@4.19.1 esquery@1.0.0 nyc@11.8.0 + - run: npm install + - if: ${{ matrix.node-version == '4.x' }} + run: npm install mocha@5.0.0 eslint@4.19.1 esquery@1.0.0 nyc@11.8.0 + - run: npm test + - run: node_modules/.bin/nyc --reporter=text-lcov node_modules/.bin/mocha | tee lcov.info + - uses: coverallsapp/github-action@master + if: ${{ matrix.node-version == '14.0' }} + with: + github-token: ${{ secrets.github_token }} + flag-name: run-${{ matrix.node-version }} + path-to-lcov: lcov.info |