Refactor repository generation within core container to re-use a call… #105
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This workflow will install Python dependencies, run tests and lint with a single version of Python | |
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-python-with-github-actions | |
name: Python application | |
on: | |
push: | |
branches: [ main ] | |
pull_request: | |
branches: [ main ] | |
permissions: | |
contents: read | |
env: | |
DATABASE_USER: db_bot | |
DATABASE_PASSWORD: test_p | |
TEST_DATABASE_NAME: test_db | |
jobs: | |
test-pipeline: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/[email protected] | |
- uses: actions/setup-python@v5 | |
with: | |
python-version: '3.11' | |
- name: Build Docker images | |
run: | | |
docker-compose build test-pipeline | |
docker-compose up -d test-db | |
- name: Check type hints | |
if: always() | |
run: docker-compose run test-pipeline mypy src | |
- name: Lint with ruff | |
if: always() | |
run: docker-compose run test-pipeline ruff src | |
- name: Test with unit pytest | |
if: always() | |
run: | | |
docker-compose run test-pipeline pytest -m "not integration" --cov-report=xml --cov=. | |
- name: Test with integration pytest | |
if: always() | |
run: | | |
docker-compose run test-pipeline pytest -m integration --cov-report=xml --cov=. --cov-append |