-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add test generation and github action execution
- Loading branch information
Showing
7 changed files
with
28 additions
and
1 deletion.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
Empty file.
6 changes: 6 additions & 0 deletions
6
...cutter.project_slug }}/src/{{ cookiecutter.project_slug }}/api/tests/test_django_setup.py
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
from django.shortcuts import resolve_url | ||
|
||
|
||
def test_openapi_schema_loads(client): | ||
response = client.get(resolve_url("openapi_schema")) | ||
assert response.status_code == 200 |
Empty file.
8 changes: 8 additions & 0 deletions
8
...utter.project_slug }}/src/{{ cookiecutter.project_slug }}/core/tests/test_django_setup.py
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
def test_django_loads(): | ||
from django.conf import settings | ||
assert len(settings.INSTALLED_APPS) > 0 | ||
|
||
|
||
@pytest.mark.django_db() | ||
def test_db_connection(django_user_model): | ||
assert django_user_model.objects.all().count() == 0 |