Commit 003bb75c authored by Vincent Pelletier's avatar Vincent Pelletier

testOOoImport: Be less sensitive to other activity sources.

parent 5574edac
...@@ -26,7 +26,7 @@ ...@@ -26,7 +26,7 @@
# #
############################################################################## ##############################################################################
from collections import Counter
import unittest import unittest
import os import os
...@@ -133,11 +133,15 @@ class TestOOoImport(TestOOoImportMixin): ...@@ -133,11 +133,15 @@ class TestOOoImport(TestOOoImportMixin):
person_module.Base_importFile(import_file=f, listbox=listbox) person_module.Base_importFile(import_file=f, listbox=listbox)
def stepCheckActivitiesCount(self, sequence=None, sequence_list=None, **kw): def stepCheckActivitiesCount(self, sequence=None, sequence_list=None, **kw):
message_list = self.getPortal().portal_activities.getMessageList() activity_count_by_method_dict = Counter(
self.assertEqual(102,len(message_list)) x.method_id
'''for i in range(101): for x in self.getPortal().portal_activities.getMessageList()
method_id = message_list[i].method_id )
self.assertEqual('Base_importFileLine',method_id)''' self.assertEqual(
101,
activity_count_by_method_dict['Base_importFileLineDefaultScript'],
activity_count_by_method_dict,
)
def stepCheckImportedPersonList(self, sequence=None, sequence_list=None, def stepCheckImportedPersonList(self, sequence=None, sequence_list=None,
num=101, **kw): num=101, **kw):
......
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