Skip to content
This repository has been archived by the owner on Sep 27, 2024. It is now read-only.

Merge pull request #389 from SELab-2/bugfix #863

Merge pull request #389 from SELab-2/bugfix

Merge pull request #389 from SELab-2/bugfix #863

Workflow file for this run

name: Backend
on: [push]
jobs:
lint:
runs-on: self-hosted
steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.12'
- name: Install Poetry
run: pip install poetry
- name: Install dependencies
run: cd backend && poetry install --no-root
- name: Lint code
run: cd backend && poetry run ruff check
- name: Run Pyright
run: cd backend && poetry run pyright
test:
runs-on: self-hosted
steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.12'
- name: Install Poetry
run: pip install poetry
- name: Install dependencies
run: cd backend && poetry install --no-root
- name: Reset database
run: psql -U githubactions -h localhost -d delphi-test -c "DROP OWNED BY current_user;"
env:
PGPASSWORD: postgres
- name: Run tests
run: cd backend && poetry run python -m unittest discover tests
env:
DB_HOST: localhost
DB_PORT: 5432
DB_USERNAME: githubactions
DB_PASSWORD: postgres
DB_DATABASE: delphi-test
DELPHI_DEBUG: 1