Tests runner dependabot/npm_and_yarn/vite-5.0.12 #37
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Tests runner | |
run-name: Tests runner ${{ github.head_ref || github.run_id }} | |
on: | |
workflow_dispatch: | |
pull_request: | |
push: | |
branches: [main] | |
# Cancel previous PR/branch runs when a new commit is pushed | |
concurrency: | |
group: ${{ github.head_ref || github.run_id }} | |
jobs: | |
# Makes sure that the published packages can be require'd without issues in a production environment | |
test-pacakges: | |
name: Packages test | |
runs-on: ubuntu-latest | |
steps: | |
- name: ⬇️ Checkout project code | |
uses: actions/checkout@v1 | |
- name: 📦 Prepare environment | |
uses: ./.github/actions/prepare-env | |
with: | |
build-only-packages: true | |
- name: ✅ Run Mocha/Chai unit tests | |
run: GITHUB_ACTION=true pnpm test:packages | |
test-server: | |
needs: [test-pacakges] | |
name: Server test | |
runs-on: ubuntu-latest | |
steps: | |
- name: ⬇️ Checkout project code | |
uses: actions/checkout@v1 | |
- name: 📦 Prepare environment | |
uses: ./.github/actions/prepare-env | |
with: | |
build-only-packages: true | |
- name: ✅ Run Mocha/Chai unit tests | |
run: GITHUB_ACTION=true pnpm coverage:junit | |
- name: ⬆️ Publish Unit Test Results | |
uses: EnricoMi/[email protected] | |
if: always() | |
with: | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
files: ./apps/server/test-results.xml | |
- name: ⬆️ Upload coverage to Codecov | |
uses: codecov/codecov-action@v2 | |
if: always() | |
with: | |
directory: ./apps/server/ |