Skip to content

Commit

Permalink
Merge pull request #91 from maykinmedia/chore/fix-local-tox
Browse files Browse the repository at this point in the history
👷 Fix running tox locally
  • Loading branch information
CharString authored Jan 30, 2025
2 parents fc45a8a + 15e67f0 commit e99cfa1
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ jobs:

- name: Run tests
run: |
tox -- ${{ matrix.oidc_enabled != 'yes' && '--ignore tests/oidc' || '' }}
tox
env:
PYTHON_VERSION: ${{ matrix.python }}
DJANGO: ${{ matrix.django }}
Expand Down
4 changes: 2 additions & 2 deletions tests/project/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -104,8 +104,8 @@
"NAME": os.getenv("PGDATABASE", "django_digid_eherkenning"),
"USER": os.getenv("PGUSER", "django_digid_eherkenning"),
"PASSWORD": os.getenv("PGPASSWORD", "django_digid_eherkenning"),
"HOST": os.getenv("DB_HOST", "localhost"),
"PORT": os.getenv("DB_PORT", 5432),
"HOST": os.getenv("PGHOST", "localhost"),
"PORT": os.getenv("PGPORT", 5432),
}
if OIDC_ENABLED
else {
Expand Down
4 changes: 3 additions & 1 deletion tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ OIDC_ENABLED =
setenv =
PYTHONPATH={toxinidir}
oidcenabled: OIDC_ENABLED=yes
oidcdisabled: IGNORE_OIDC=--ignore tests/oidc
passenv =
OIDC_ENABLED
PGUSER
Expand All @@ -40,12 +41,13 @@ deps =
commands =
pytest tests \
--cov --cov-report xml:reports/coverage-{envname}.xml \
{env:IGNORE_OIDC} \
{posargs}

[testenv:isort]
extras = tests
skipsdist = True
commands = isort --check-only --diff .
commands = isort --check-only --diff digid_eherkenning tests

[testenv:black]
extras = tests
Expand Down

0 comments on commit e99cfa1

Please sign in to comment.