diff --git a/product/ERP5Catalog/tests/testERP5Catalog.py b/product/ERP5Catalog/tests/testERP5Catalog.py index 1d53bd473229d4a59eccb47a9a69729ffe104ab6..8de4254b0812fa6ab353c8b802bf4a56ba4b7943 100755 --- a/product/ERP5Catalog/tests/testERP5Catalog.py +++ b/product/ERP5Catalog/tests/testERP5Catalog.py @@ -54,6 +54,11 @@ import os from Products.ERP5Type import product_path from DateTime import DateTime +try: + from transaction import get as get_transaction +except ImportError: + pass + class TestERP5Catalog(ERP5TypeTestCase): """ This is the list of test @@ -466,6 +471,10 @@ class TestERP5Catalog(ERP5TypeTestCase): get_transaction().commit() self.tic() # Check catalog + organisation.reindexObject() + # Commit + get_transaction().commit() + self.tic() sql = 'select count(*) from message' result = sql_connection.manage_test(sql) message_count = result[0]['COUNT(*)']