| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
name: Run Tests |
| 5 |
|
| 6 |
on: |
| 7 |
push: |
| 8 |
branches: [master] |
| 9 |
pull_request: |
| 10 |
branches: [master] |
| 11 |
|
| 12 |
jobs: |
| 13 |
build: |
| 14 |
runs-on: ubuntu-latest |
| 15 |
|
| 16 |
steps: |
| 17 |
- uses: actions/checkout@v4 |
| 18 |
- name: Set up Python |
| 19 |
uses: actions/[email protected] |
| 20 |
with: |
| 21 |
python-version: "3.12" |
| 22 |
- name: Install dependencies |
| 23 |
run: | |
| 24 |
pip install ".[requirements, requirements-test]" |
| 25 |
- name: Check lint with Ruff |
| 26 |
run: | |
| 27 |
ruff check pydeconz tests |
| 28 |
- name: Check formatting with ruff |
| 29 |
run: | |
| 30 |
ruff format --check pydeconz tests |
| 31 |
- name: Check typing with mypy |
| 32 |
run: | |
| 33 |
mypy pydeconz |
| 34 |
- name: Test with pytest |
| 35 |
run: | |
| 36 |
pytest tests --doctest-modules --junitxml=junit/test-results.xml --cov=pydeconz --cov-report=xml --cov-report=html |