Skip to content

add destruction check to e2e test #2248

add destruction check to e2e test

add destruction check to e2e test #2248

Workflow file for this run

name: Code quality checks
# Run this workflow every time a new commit pushed to your repository
on:
push:
branches:
- main
- stable/*
tags:
paths:
- '**.py'
- '**.json'
- '**.yaml'
- '**.in'
pull_request:
paths:
- '**.py'
- '**.json'
- '**.yaml'
- '**.in'
workflow_dispatch:
jobs:
ruff:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6.0.3
with:
persist-credentials: false
- uses: astral-sh/ruff-action@0ce1b0bf8b818ef400413f810f8a11cdbda0034b # v4.0.0 (runs ruff check)
- name: Check formatting
run: ruff format --check
migrations:
name: Check for model changes not present in migrations
runs-on: ubuntu-latest
defaults:
run:
working-directory: backend
services:
postgres:
image: postgis/postgis:14-3.4
env:
POSTGRES_HOST_AUTH_METHOD: trust
ports:
- 5432:5432
# Needed because the postgres container does not provide a healthcheck
options:
--health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5
steps:
- uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6.0.3
with:
persist-credentials: false
- name: Set up backend environment
uses: maykinmedia/setup-django-backend@4a6c5facc65bb1dd510cf06be20871db11a156b3 # v1.4.2
with:
apt-packages: 'gettext postgresql-client libgdal-dev gdal-bin'
python-version: '3.12'
setup-node: 'no'
working-directory: backend
- name: Run makemigrations to check for missing migrations
working-directory: backend
run: |
src/manage.py makemigrations \
--check \
--dry-run
env:
DJANGO_SETTINGS_MODULE: "openarchiefbeheer.conf.ci"
DEBUG: 'true'
SECRET_KEY: dummy
DB_USER: postgres
DB_NAME: postgres
DB_PASSWORD: ''