From 04fa8bdc6220b0b742cb35a5f3c32c84910c2cbe Mon Sep 17 00:00:00 2001 From: Kazuhiko Shiozaki <kazuhiko@nexedi.com> Date: Tue, 29 Dec 2009 16:37:26 +0000 Subject: [PATCH] oops, test invalidation should be done in afterSetUp() otherwise TestPackingListMixin.afterSetUp() will validate all existing rules. git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@31523 20353a03-c40f-0410-a6d1-a30d3c3de9de --- product/ERP5/tests/testERP5Simulation.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/product/ERP5/tests/testERP5Simulation.py b/product/ERP5/tests/testERP5Simulation.py index 25aef842cb..abea42831b 100644 --- a/product/ERP5/tests/testERP5Simulation.py +++ b/product/ERP5/tests/testERP5Simulation.py @@ -45,13 +45,11 @@ class TestERP5SimulationMixin(TestPackingListMixin): def afterSetUp(self, quiet=1, run=1): TestPackingListMixin.afterSetUp(self, quiet, run) - self.validateNewRules() - - def beforeTearDown(self): portal_rules = self.portal.portal_rules for rule in portal_rules.objectValues(portal_type='New Order Rule'): if rule.getValidationState() == 'validated': rule.invalidate() + self.validateNewRules() class TestERP5Simulation(TestERP5SimulationMixin, ERP5TypeTestCase): run_all_test = 1 -- 2.30.9