Fixed test and jenkins file

This commit is contained in:
JKuijperM 2026-07-24 10:04:28 +02:00
parent ed17d27457
commit e621a6f9f0
2 changed files with 3 additions and 2 deletions

View File

@ -2,6 +2,7 @@ pipeline{
agent any
environment {
DEBUG = 'TRUE'
DJANGO_SECRET_KEY = 'test-secret-key-for-ci'
DJANGO_SETTINGS_MODULE = "expenses_manager.settings"
PYTHONUNBUFFERED = "1"
@ -33,7 +34,6 @@ pipeline{
cd expenses_manager
. venv/bin/activate
export SECRET_KEY=$DJANGO_SECRET_KEY
venv/bin/pytest --cov
'''
}

View File

@ -158,6 +158,7 @@ DATETIME_INPUT_FORMATS = ["%d/%m/%Y %H:%M"]
STATIC_URL = '/static/'
STATIC_ROOT = BASE_DIR / 'staticfiles'
if not DEBUG:
STATICFILES_STORAGE = "whitenoise.storage.CompressedManifestStaticFilesStorage"
# Default primary key field type