---
name: Tests

on:
  push:
    branches: [master]
  pull_request:
    branches: [master]

jobs:
  build:

    runs-on: ubuntu-latest

    strategy:
      matrix:
        node-version: [10.x, 12.x, 14.x, 15.x]

    steps:
      - uses: actions/checkout@v2
        with:
          submodules: true
      - name: Use Node.js ${{ matrix.node-version }}
        uses: actions/setup-node@v1
        with:
          node-version: ${{ matrix.node-version }}
      - name: Install test tools
        run: npm install nyc mocha chai
      - name: Test ${{ matrix.node-version }}
        run: npm run lcov
      - name: Coveralls Parallel
        uses: coverallsapp/github-action@master
        with:
          github-token: ${{ secrets.github_token }}
          flag-name: node-${{ matrix.node-version }}
          parallel: true
  finish:
    needs: build
    runs-on: ubuntu-latest
    steps:
      - name: Coveralls Finished
        uses: coverallsapp/github-action@master
        with:
          github-token: ${{ secrets.github_token }}
          parallel-finished: true

---
name: Tests

on:
  push:
    branches: [master]
  pull_request:
    branches: [master]

jobs:
  build:

    runs-on: ubuntu-latest

    strategy:
      matrix:
        node-version: [10.x, 12.x, 14.x, 15.x]

    steps:
      - uses: actions/checkout@v2
        with:
          submodules: true
      - name: Use Node.js ${{ matrix.node-version }}
        uses: actions/setup-node@v1
        with:
          node-version: ${{ matrix.node-version }}
      - name: Install production dependencies
        run: npm install --only=prod
      - name: Install test tools
        run: npm install nyc mocha chai
      - name: Test ${{ matrix.node-version }}
        run: npm run lcov
      - name: Coveralls Parallel
        uses: coverallsapp/github-action@master
        with:
          github-token: ${{ secrets.github_token }}
          flag-name: node-${{ matrix.node-version }}
          parallel: true
  finish:
    needs: build
    runs-on: ubuntu-latest
    steps:
      - name: Coveralls Finished
        uses: coverallsapp/github-action@master
        with:
          github-token: ${{ secrets.github_token }}
          parallel-finished: true

Install dependencies in CI, now that we have some
Install dependencies in CI, now that we have some
