Commit ab1b8bf6 authored by Kazuhiko Shiozaki's avatar Kazuhiko Shiozaki

isPropertyRecorded() requires an argument.


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@31109 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 0f113b27
......@@ -65,7 +65,8 @@ class CategoryMembershipDivergenceTester(Predicate, DivergenceTesterMixin):
list : (prevision_value, decision_value, message, mapping)
"""
tested_property = self.getTestedProperty()
if getattr(decision_movement, 'isPropertyRecorded', lambda:False)():
if getattr(decision_movement, 'isPropertyRecorded',
lambda x:False)(tested_property):
decision_value = decision_movement.getRecordedProperty(tested_property)
else:
decision_value = decision_movement.getPropertyList(tested_property)
......
......@@ -67,7 +67,9 @@ class FloatDivergenceTester(Predicate, DivergenceTesterMixin):
list : (prevision_value, decision_value, message, mapping)
"""
tested_property = self.getTestedProperty()
if getattr(decision_movement, 'isPropertyRecorded', lambda:False)():
print (tested_property, prevision_movement, decision_movement)
if getattr(decision_movement, 'isPropertyRecorded',
lambda x:False)(tested_property):
decision_value = decision_movement.getRecordedProperty(tested_property)
else:
decision_value = decision_movement.getProperty(tested_property)
......
......@@ -68,7 +68,8 @@ class StringDivergenceTester(Predicate, DivergenceTesterMixin):
list : (prevision_value, decision_value, message, mapping)
"""
tested_property = self.getTestedProperty()
if getattr(decision_movement, 'isPropertyRecorded', lambda:False)():
if getattr(decision_movement, 'isPropertyRecorded',
lambda x:False)(tested_property):
decision_value = decision_movement.getRecordedProperty(tested_property)
else:
decision_value = decision_movement.getProperty(tested_property)
......
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