Skip to content

Commit

Permalink
Run collectstatic before run tests in django.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
Fer-Bar committed May 27, 2024
1 parent b64a181 commit 3435615
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
2 changes: 2 additions & 0 deletions .github/workflows/django.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,5 +30,7 @@ jobs:
run: echo "SECRET_KEY=${SECRET_KEY}" > ./envs/.env
- name: Install Dependencies
run: poetry install
- name: Collect Static Files
run: python manage.py collectstatic --no-input
- name: Run Tests
run: poetry run python manage.py test
5 changes: 4 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,4 +37,7 @@ poetry install
2. Ejecuta el servidor de desarrollo de Django:
```bash
poetry run python manage.py runserver
```
```

## Errors
En ocasiones los tests no corren porque el STORAGES.staticfiles apunta a whitenoise, pero si lo usamos por el que usa django por defecto ```django.contrib.staticfiles.storage.StaticFilesStorage``` anda todo bien.

0 comments on commit 3435615

Please sign in to comment.