Commit 69092ae7 authored by Jérome Perrin's avatar Jérome Perrin

test that one can force a different portal type than the guessed one (it was

not working in 5.4.5)


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@35380 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent b44d990f
......@@ -1322,6 +1322,15 @@ class TestDocument(TestDocumentMixin):
self.assertEquals('File', document.getPortalType())
self.assertEquals(contributed_document, document)
def test_Base_createNewFile_forced_type(self):
"""Test contributing while forcing the portal type.
"""
person = self.portal.person_module.newContent(portal_type='Person')
contributed_document = person.Base_contribute(
portal_type='PDF',
file=makeFileUpload('TEST-en-002.odt'))
self.assertEquals('PDF', contributed_document.getPortalType())
def test_HTML_to_ODT_conversion_keep_enconding(self):
"""This test perform an PDF conversion of HTML content
then to plain text.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment