mirror of
https://github.com/django/django.git
synced 2025-10-31 09:41:08 +00:00
Fixed #31789 -- Added a new headers interface to HttpResponse.
This commit is contained in:
committed by
Mariusz Felisiak
parent
71ae1ab012
commit
bcc2befd0e
@@ -1481,7 +1481,7 @@ class NonHTMLResponseExceptionReporterFilter(ExceptionReportTestMixin, LoggingCa
|
||||
@override_settings(DEBUG=True, ROOT_URLCONF='view_tests.urls')
|
||||
def test_non_html_response_encoding(self):
|
||||
response = self.client.get('/raises500/', HTTP_ACCEPT='application/json')
|
||||
self.assertEqual(response['Content-Type'], 'text/plain; charset=utf-8')
|
||||
self.assertEqual(response.headers['Content-Type'], 'text/plain; charset=utf-8')
|
||||
|
||||
|
||||
class DecoratorsTests(SimpleTestCase):
|
||||
|
||||
Reference in New Issue
Block a user