Skip to content

Feature/add dependabot #6

Feature/add dependabot

Feature/add dependabot #6

Workflow file for this run

name: CI
on:
pull_request:
branches: [develop]
push:
branches: [develop]
jobs:
test:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ['3.9', '3.10', '3.11', '3.12']
steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Cache pip
uses: actions/cache@v4
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ matrix.python-version }}-${{ hashFiles('pyproject.toml') }}
restore-keys: |
${{ runner.os }}-pip-${{ matrix.python-version }}-
${{ runner.os }}-pip-
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install .[dev]
- name: Run pre-commit
run: |
python -m pip install pre-commit pytest
pre-commit run --all-files
- name: Run tests
run: python -m pytest --cov=xyz2graph --cov-report=xml
- name: Upload coverage
if: matrix.python-version == '3.12'
uses: codecov/codecov-action@v4
with:
file: coverage.xml
- name: Run linter
run: python -m ruff check .
- name: Run type checker
run: python -m mypy .