🐛 [#578] Fix nummer __str__ #592
Workflow file for this run
This file contains hidden or 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
| name: bin-check.yml | |
| on: | |
| push: | |
| branches: | |
| - main | |
| tags: | |
| - "*" | |
| pull_request: | |
| workflow_dispatch: | |
| jobs: | |
| dump_data: | |
| name: Test dump_data.sh | |
| runs-on: ubuntu-latest | |
| services: | |
| postgres: | |
| image: postgis/postgis:16-3.5 | |
| 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@v4 | |
| - name: Set up backend environment | |
| uses: maykinmedia/setup-django-backend@v1.3 | |
| with: | |
| apt-packages: "postgresql-client" | |
| python-version: "3.12" | |
| optimize-postgres: "no" | |
| setup-node: "no" | |
| - name: Run setup db & dump data | |
| run: | | |
| createdb -h localhost -U postgres openklant | |
| python src/manage.py migrate | |
| src/manage.py loaddata klantinteracties contactgegevens | |
| SCRIPTPATH=bin DUMP_FILE=dump.sql bin/dump_data.sh --combined | |
| SCRIPTPATH=bin TAR_FILE=dump.tar bin/dump_data.sh --csv | |
| env: | |
| DB_PASSWORD: "" | |
| DB_USER: postgres | |
| DB_NAME: openklant | |
| DB_HOST: localhost | |
| SECRET_KEY: secret | |
| DJANGO_SETTINGS_MODULE: openklant.conf.ci | |
| ALLOWED_HOSTS: localhost,127.0.0.1 | |
| - name: validate dump | |
| run: | | |
| grep "COPY public.klantinteracties_digitaaladres" dump.sql | |
| grep "COPY public.contactgegevens_persoon" dump.sql | |
| ! grep "COPY public.auth_group" dump.sql | |
| - name: load into other db | |
| run: | | |
| createdb -h localhost -U postgres test | |
| psql -v ON_ERROR_STOP=1 -h localhost -U postgres -d test -f dump.sql | |
| - name: validate csv dump | |
| run: | | |
| tar -xf dump.tar | |
| test -f klantinteracties_digitaaladres.csv || exit 1 | |
| ! test -f auth_group.csv || exit 1 | |
| grep "id,uuid,soort_digitaal_adres,adres,omschrijving,betrokkene_id,partij_id,is_standaard_adres,referentie,verificatie_datum" klantinteracties_digitaaladres.csv |