Commit 5bb06e97 authored by Łukasz Nowak's avatar Łukasz Nowak

Allow stepTic to work *before* alarm is installed.

parent c76a65cc
...@@ -333,17 +333,21 @@ class testVifibMixin(ERP5TypeTestCase): ...@@ -333,17 +333,21 @@ class testVifibMixin(ERP5TypeTestCase):
self.portal.portal_alarms.vifib_trigger_build.activeSense() self.portal.portal_alarms.vifib_trigger_build.activeSense()
def stepTic(self, **kw): def stepTic(self, **kw):
def build(**kw):
if 'vifib_trigger_build' in self.portal.portal_alarms.objectIds():
self.stepTriggerBuild(**kw)
if kw.get('sequence', None) is None: if kw.get('sequence', None) is None:
# in case of using not in sequence commit transaction # in case of using not in sequence commit transaction
transaction.commit() transaction.commit()
# trigger build before tic # trigger build before tic
self.stepTriggerBuild(**kw) build(**kw)
transaction.commit() transaction.commit()
super(testVifibMixin, self).stepTic(**kw) super(testVifibMixin, self).stepTic(**kw)
# retrigger build after tic # retrigger build after tic
self.stepTriggerBuild(**kw) build(**kw)
transaction.commit() transaction.commit()
# tic after build # tic after build
......
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