Commit 04e9ea3b authored by Jérome Perrin's avatar Jérome Perrin

If there are more than one path defined in the category upload spreadsheets

(for instance more than one * in paths columns), this is an error that should
be reported.


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@32186 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 4182a9e1
......@@ -960,6 +960,19 @@ class TestOOoImport(ERP5TypeTestCase):
else:
self.fail('ValueError not raised')
def test_Base_getCategoriesSpreadSheetMapping_MultiplePaths(self):
# If multiple paths is defined (for instance more than one * in paths
# columns), then it should be an error and the error must be reported
import_file = makeFileUpload(
'import_region_category_multiple_paths.ods')
try:
self.portal.portal_categories.Base_getCategoriesSpreadSheetMapping(
import_file=import_file)
except ValueError, error:
self.assertTrue('More that one path is defined' in str(error), str(error))
else:
self.fail('ValueError not raised')
def test_Base_getCategoriesSpreadSheetMapping_Id_is_reserved_property_name(self):
# tests Base_getCategoriesSpreadSheetMapping reserved property name are only test for path column, not all.
import_file = makeFileUpload(
......
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