Skip to content

Add CI/CD workflows and AI agent quality check documentation #7

Add CI/CD workflows and AI agent quality check documentation

Add CI/CD workflows and AI agent quality check documentation #7

Workflow file for this run

name: Backend CI
on:
push:
branches: [ main ]
paths:
- 'service/**'
- '.github/workflows/backend-ci.yml'
pull_request:
branches: [ main ]
paths:
- 'service/**'
- '.github/workflows/backend-ci.yml'
permissions:
contents: read
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.12'
- name: Install dependencies
run: |
cd service
pip install -r requirements.txt
pip install coverage
- name: Run tests with coverage
run: |
cd service
coverage run --source='.' manage.py test
coverage report --fail-under=80
coverage xml
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v3
with:
files: ./service/coverage.xml
flags: backend
fail_ci_if_error: false
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.12'
- name: Install linters
run: pip install black flake8
- name: Run black
run: black --check service/
- name: Run flake8
run: flake8 service/