Skip to content

🧱 ci: Correcting Isort version in CI #4

🧱 ci: Correcting Isort version in CI

🧱 ci: Correcting Isort version in CI #4

Workflow file for this run

on: [ push, pull_request ]
name: CI
jobs:
ruff:
name: Ruff
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: chartboost/ruff-action@v1
with:
version: "0.1.3"
isort:
name: Isort
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: isort/isort-action@v1
with:
sort-paths: "statbov"
requirements-files: "requirements.txt"
configuration: "--profile django -l 79 --extend-skip migrations"
tests:
name: Tests
runs-on: ubuntu-latest
strategy:
max-parallel: 4
matrix:
python-version: [ 3.12 ]
env:
DJANGO_SETTINGS_MODULE: ${{ secrets.DJANGO_SETTINGS_MODULE }}
DEBUG: ${{ secrets.DEBUG }}
SECRET_KEY: ${{ secrets.SECRET_KEY }}
DB_ENGINE: ${{ secrets.DB_ENGINE }}
POSTGRES_DB: ${{ secrets.POSTGRES_DB }}
ALLOWED_HOSTS: ${{ secrets.ALLOWED_HOSTS }}
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v3
with:
python-version: ${{ matrix.python-version }}
- name: Install Dependencies
run: |
python -m pip install --upgrade pip
pip install poetry
poetry config virtualenvs.create false
poetry install
- name: Run Tests
run: |
python manage.py collectstatic --noinput
python manage.py check
python manage.py migrate
pytest -m "not functional_test" -s -x --cov=project -vv
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v3
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}