diff options
author | Matthew Lemon <y@yulqen.org> | 2024-06-22 16:38:00 +0100 |
---|---|---|
committer | Matthew Lemon <y@yulqen.org> | 2024-06-22 16:38:00 +0100 |
commit | 9667a4868760741fab894ef88e403f7ecb512e61 (patch) | |
tree | 77f6637720e9c545de6849d40ccf050e88d17937 /pyblackbird_cc/resources | |
parent | dffe4f530812ff4087622523a598085255abc00c (diff) |
Better use of pytest-django mark
Diffstat (limited to 'pyblackbird_cc/resources')
-rw-r--r-- | pyblackbird_cc/resources/tests/test_views.py | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/pyblackbird_cc/resources/tests/test_views.py b/pyblackbird_cc/resources/tests/test_views.py index 123476f..0cf242f 100644 --- a/pyblackbird_cc/resources/tests/test_views.py +++ b/pyblackbird_cc/resources/tests/test_views.py @@ -9,20 +9,19 @@ from django.test import TestCase from django.urls import reverse from .. import services +from ..forms import ResourceCreateForm from ..models import ResourceCategory from ..models import ResourceType -from ..forms import ResourceCreateForm from ..views import create_resource +pytestmark = pytest.mark.django_db -@pytest.mark.django_db() def test_create_featured_resource_view(client): url = reverse("resources:create_featured") response = client.get(url) assert response.status_code == 302 -@pytest.mark.django_db() def test_create_resource_view(client): url = reverse("resources:create_resource") response = client.get(url) |