Skip to content

add mypy to CI

add mypy to CI #29

Workflow file for this run

name: CI
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
test:
name: test
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up Python 3.13
uses: actions/setup-python@v4
with:
python-version: "3.13"
- name: Install PDM
run: |
python -m pip install --upgrade pip
pip install pdm
- name: Install dependencies
run: |
pdm install -G:all
- name: Run tests with coverage
run: |
pdm run pytest --cov=fitbit_client --cov-report=xml:coverage.xml
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v5
with:
token: ${{ secrets.CODECOV_TOKEN }}
files: ./coverage.xml
# fail_ci_if_error: false
name: codecov-umbrella
verbose: true
mypy:
name: mypy
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up Python 3.13
uses: actions/setup-python@v4
with:
python-version: "3.13"
- name: Install PDM
run: |
python -m pip install --upgrade pip
pip install pdm
- name: Install dependencies
run: |
pdm install -G:all
- name: Verify type hints
run: |
pdm run mypy