From d664c7763ac42495c7144f9d6f9c692b433545c4 Mon Sep 17 00:00:00 2001 From: Jesse Breuer-Penello Date: Thu, 14 Sep 2023 13:46:42 -0400 Subject: [PATCH] ci: mv jest to own workflow & add codecov --- .github/workflows/code-review.yml | 2 -- .github/workflows/jest.yml | 30 ++++++++++++++++++++++++++++++ 2 files changed, 30 insertions(+), 2 deletions(-) create mode 100644 .github/workflows/jest.yml diff --git a/.github/workflows/code-review.yml b/.github/workflows/code-review.yml index 6bd2254..2ffa400 100644 --- a/.github/workflows/code-review.yml +++ b/.github/workflows/code-review.yml @@ -27,7 +27,5 @@ jobs: run: npm run prettier - name: Run ESLint run: npm run lint - - name: Run Jest - run: npm run test - name: Run build run: npm run build diff --git a/.github/workflows/jest.yml b/.github/workflows/jest.yml new file mode 100644 index 0000000..d3deea7 --- /dev/null +++ b/.github/workflows/jest.yml @@ -0,0 +1,30 @@ +name: Jest + +on: + pull_request: + branches: + - main + +env: + GIT_PAT: ${{ secrets.GIT_PAT }} + GIT_USERNAME: ${{ secrets.GIT_USERNAME }} + CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} + +jobs: + jest: + name: Run Jest + runs-on: ubuntu-latest + steps: + - name: Check out repo + uses: actions/checkout@v3 + - name: Setup node with npm + uses: actions/setup-node@v3 + with: + node-version: 18 + cache: 'npm' + - name: Download dependencies + run: npm ci + - name: Run Jest + run: npm run test + - name: Upload coverage reports to Codecov + uses: codecov/codecov-action@v3