Skip to content

Merge pull request #6 from CSC-510-G55/feature-pytest #29

Merge pull request #6 from CSC-510-G55/feature-pytest

Merge pull request #6 from CSC-510-G55/feature-pytest #29

Workflow file for this run

name: Unit Test
on:
push:
branches:
- main
pull_request:
branches:
- main
jobs:
unit-tests:
name: Unit Tests
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Set up Environment
run: |
chmod +x ./.github/workflows/setup.sh && ./.github/workflows/setup.sh
pip install pytest pytest-cov
- name: Test with pytest
run: |
pytest --doctest-modules --junitxml=junit/test-results.xml --cov=hw2_debugging --cov-report=xml --cov-report=html
- name: Upload coverage to Codecov
if: always()
uses: codecov/codecov-action@v3
with:
files: ./coverage.xml
flags: unittests
name: codecov-umbrella
fail_ci_if_error: false
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}