Skip to content

Commit

Permalink
added codecov (#3)
Browse files Browse the repository at this point in the history
* added codecov

* fix coverage of tests

---------

Co-authored-by: Vipul-Cariappa <[email protected]>
  • Loading branch information
Vipul-Cariappa and Vipul-Cariappa authored Dec 2, 2023
1 parent 6de64da commit 6c33de0
Showing 1 changed file with 13 additions and 2 deletions.
15 changes: 13 additions & 2 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,18 +20,22 @@ jobs:

steps:
- uses: actions/checkout@v3

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v3
with:
python-version: ${{ matrix.python-version }}

- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install flake8 mypy pylint
python -m pip install flake8 mypy pylint coverage
if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
- name: Lint with flake8
run: |
flake8 ./tests/*.py ./logic/*.py --max-line-length=120
- name: Lint with pylint
continue-on-error: true
run: |
Expand All @@ -47,6 +51,13 @@ jobs:
- name: Type checker with mypy
run: |
mypy ./tests/*.py ./logic/*.py
- name: Test with python unittest
run: |
python -m unittest tests/*.py --verbose
coverage run --omit="*/test*" -m unittest discover --verbose
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v3
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}

0 comments on commit 6c33de0

Please sign in to comment.