From 907b15944143eadf986cbc4dd9a88d71df71ef50 Mon Sep 17 00:00:00 2001 From: Luciano Frizzera Date: Tue, 3 Aug 2021 20:49:10 -0400 Subject: [PATCH] Update main.yml --- .github/workflows/main.yml | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index c7bfadd..6e04ecb 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -7,12 +7,37 @@ on: branches: [master, main] tags: - "v*.*.*" + pull_request: + branches: [master, main] # Allows you to run this workflow manually from the Actions tab workflow_dispatch: jobs: + + run_tests_on_nodejs: + name: run tests on nodejs + runs-on: ubuntu-latest + + strategy: + matrix: + node-version: [12.x, 14.x, 16.x] + + steps: + - uses: actions/checkout@v2 + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v2 + with: + node-version: ${{ matrix.node-version }} + cache: 'npm' + - run: npm install + - run: npm test + - name: check coverage + if: ${{ success() }} + run: npm run check-coverage + docker: + needs: run_tests_on_nodejs runs-on: ubuntu-latest steps: - name: Checkout