We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 00e5065 commit ae86577Copy full SHA for ae86577
tests/test_negotiation.py
@@ -1,7 +1,7 @@
1
import pytest
2
-from django.http import Http404
3
from django.test import TestCase
4
+from rest_framework.exceptions import NotAcceptable
5
from rest_framework.negotiation import (
6
BaseContentNegotiation, DefaultContentNegotiation
7
)
@@ -81,7 +81,7 @@ def test_raise_error_if_no_suitable_renderers_found(self):
81
class MockRenderer:
82
format = 'xml'
83
renderers = [MockRenderer()]
84
- with pytest.raises(Http404):
+ with pytest.raises(NotAcceptable):
85
self.negotiator.filter_renderers(renderers, format='json')
86
87
0 commit comments