Skip to content

Commit

Permalink
Merge branch '#105'
Browse files Browse the repository at this point in the history
  • Loading branch information
nothingface0 committed Mar 17, 2022
2 parents 3cc3477 + bfcdd95 commit 0a78a0e
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions trackermaps/tests/test_trackermaps_views.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,14 @@
import pytest
from django.test import RequestFactory
from django.urls import reverse
from users.models import User
from trackermaps.views import maps
from mixer.backend.django import mixer

logger = logging.getLogger(__name__)

pytestmark = pytest.mark.django_db


class TestTrackermapsJSONResponses:
def test_400_response(self):
Expand All @@ -18,5 +22,6 @@ def test_400_response(self):
req = RequestFactory().post(reverse('trackermaps:maps'),
data=arguments,
HTTP_X_REQUESTED_WITH='XMLHttpRequest')
req.user = mixer.blend(User)
resp = maps(req)
assert resp.status_code == 400

0 comments on commit 0a78a0e

Please sign in to comment.