Skip to content

feat: 16 naming conventions #90

feat: 16 naming conventions

feat: 16 naming conventions #90

Workflow file for this run

# This workflow will install Python dependencies, run tests and lint with a variety of Python versions
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-python
name: CI
on:
push:
branches:
- main
pull_request:
branches:
- main
jobs:
test:
name: Test
runs-on: macos-latest
strategy:
fail-fast: false
matrix:
python-version: ["3.9", "3.10", "3.11", "3.12"]
steps:
- name: Checkout code 📂
uses: actions/checkout@v4
- name: Setup Rye 🌾
id: setup-rye
uses: eifinger/setup-rye@v3
with:
version: "0.35.0"
enable-cache: true
cache-prefix: ${{ matrix.python-version }}
- name: Pin python-version ${{ matrix.python-version }} 📌
if: steps.setup-rye.outputs.cache-hit != 'true'
run: rye pin ${{ matrix.python-version }}
- name: Install dependencies 🛠️
if: steps.setup-rye.outputs.cache-hit != 'true'
run: |
rye sync --no-lock
- name: Cache pre-commit 📦
uses: actions/cache@0c45773b623bea8c8e75f6c82b208c3cf94ea4f9
with:
path: ~/.cache/pre-commit
key: pre-commit-${{ matrix.python-version }}-${{ hashFiles('.pre-commit-config.yaml') }}
- name: Run pre-commit 🚦
run: |
rye run pre-commit run --all-files --show-diff-on-failure --color always
- name: Run tests 🧪
run: |
rye test
- name: Upload coverage report to Codecov 📈
uses: codecov/codecov-action@v3
with:
token: ${{ secrets.CODECOV_TOKEN }}
file: ./coverage.xml
flags: unittests