Skip to content

Commit

Permalink
github: add a new workflow for tests.
Browse files Browse the repository at this point in the history
Signed-off-by: Romain Bezut <[email protected]>
  • Loading branch information
morian committed Sep 25, 2024
1 parent 3070170 commit d518167
Show file tree
Hide file tree
Showing 3 changed files with 26 additions and 5 deletions.
6 changes: 2 additions & 4 deletions .github/workflows/mypy.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: "Type checks with MyPy"
name: "Check typing with MyPy"
on:
push:
paths:
Expand All @@ -22,8 +22,6 @@ jobs:
with:
python-version: ${{ env.PYTHON_VERSION }}
- name: "Install linting dependendies"
run: |
python -m pip install --upgrade pip
make install install-linting
run: make install-package install-linting
- name: "Run mypy"
run: mypy
23 changes: 23 additions & 0 deletions .github/workflows/pytest.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: "Test package with pytest"
on: [push, pull_request, workflow_dispatch]

jobs:
pytest:
name: "Run tests"
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.9", "3.10", "3.11", "3.12"]

steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: "Install testing dependendies"
run: make install-testing
- name: "Test the package"
run: pytest --cov=aio_ld2410 -v -s
- name: "Generate a coverage report"
run: coverage report --show-missing
if: success() || failure()
2 changes: 1 addition & 1 deletion .github/workflows/ruff.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: "Linting checks with ruff"
name: "Check linting with ruff"
on:
push:
paths:
Expand Down

0 comments on commit d518167

Please sign in to comment.