Rename the request_data variable to querystring for clarity. Turn the querystring into an IRI to support international characters in metadata values and allow JSON serializer for Celery.

Signed-off-by: Michael Price <loneviking72@gmail.com>
This commit is contained in:
Michael Price
2018-04-01 20:30:40 -04:00
committed by Roberto Rosario
parent b200438c4e
commit e9a365333f
8 changed files with 51 additions and 39 deletions
+3 -2
View File
@@ -147,12 +147,13 @@ class DocumentUploadMetadataTestCase(MetadataTypeMixin, GenericDocumentViewTestC
# Upload the test document
with open(TEST_SMALL_DOCUMENT_PATH) as file_descriptor:
self.post(
response = self.post(
path=url, data={
'document-language': 'eng', 'source-file': file_descriptor,
'document_type_id': self.document_type.pk,
}, follow=True
}
)
self.assertEqual(response.status_code, 302)
self.assertEqual(Document.objects.count(), 1)
self.assertEqual(
Document.objects.first().metadata.first().value,