Set the proper expected response content type in the document download views tests.
This commit is contained in:
@@ -247,6 +247,9 @@ class DocumentsViewsTestCase(GenericDocumentViewTestCase):
|
||||
permission_document_download.stored_permission
|
||||
)
|
||||
|
||||
# Set the expected_content_type for common.tests.mixins.ContentTypeCheckMixin
|
||||
self.expected_content_type = self.document.file_mimetype
|
||||
|
||||
response = self.post(
|
||||
'documents:document_download', args=(self.document.pk,)
|
||||
)
|
||||
@@ -284,6 +287,9 @@ class DocumentsViewsTestCase(GenericDocumentViewTestCase):
|
||||
permission_document_download.stored_permission
|
||||
)
|
||||
|
||||
# Set the expected_content_type for common.tests.mixins.ContentTypeCheckMixin
|
||||
self.expected_content_type = self.document.file_mimetype
|
||||
|
||||
response = self.post(
|
||||
'documents:document_multiple_download',
|
||||
data={'id_list': self.document.pk}
|
||||
@@ -323,6 +329,9 @@ class DocumentsViewsTestCase(GenericDocumentViewTestCase):
|
||||
permission_document_download.stored_permission
|
||||
)
|
||||
|
||||
# Set the expected_content_type for common.tests.mixins.ContentTypeCheckMixin
|
||||
self.expected_content_type = self.document.file_mimetype
|
||||
|
||||
response = self.post(
|
||||
'documents:document_version_download', args=(
|
||||
self.document.latest_version.pk,
|
||||
|
||||
Reference in New Issue
Block a user