Skip to content

Feature/e2etest

Feature/e2etest #89

Workflow file for this run

name: Test Codebase
on:
push:
branches: [ main, develop ]
pull_request:
branches: [ main, develop ]
permissions:
contents: read
jobs:
start:
name: Initial Setup
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
- name: Starting Job
run: |
echo "Beginning to test ${{ github.repository }}"
run_tests:
name: Test Codebase
needs: start
runs-on: ubuntu-latest
steps:
- name: Checkout "${{ github.repository }}"
uses: actions/checkout@v4
- name: Set up Node v21
uses: actions/setup-node@v4
with:
node-version: '21.x'
- name: Install dependencies
run: |
cd CoVAR-app && npm ci
- name: Test Codebase
run: |
cd CoVAR-app && npm run test
- name: Jest Coverage Comment
id: coverageComment
uses: MishaKav/jest-coverage-comment@main
with:
hide-comment: true
coverage-summary-path: ./CoVAR-app/coverage/coverage-summary.json
- name: Check the output coverage
run: |
echo "Coverage Percentage - ${{ steps.coverageComment.outputs.coverage }}"
echo "Coverage Color - ${{ steps.coverageComment.outputs.color }}"
echo "Summary HTML - ${{ steps.coverageComment.outputs.summaryHtml }}"
end:
name: The end
runs-on: ubuntu-latest
needs: [start, run_tests]
steps:
- name: Ending
id: init
run: |
echo "${{ github.repository }} has passed all tests"