From d56a7a6e4cda81ba20352b2301e7d4871fe5224f Mon Sep 17 00:00:00 2001 From: Alexandre Boeglin <alex@nexedi.com> Date: Wed, 20 Sep 2006 11:42:16 +0000 Subject: [PATCH] fixed account and accounting_transaction creation git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@10209 20353a03-c40f-0410-a6d1-a30d3c3de9de --- product/ERP5/tests/testERP5Budget.py | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/product/ERP5/tests/testERP5Budget.py b/product/ERP5/tests/testERP5Budget.py index 32df176dba..b37b42dcef 100644 --- a/product/ERP5/tests/testERP5Budget.py +++ b/product/ERP5/tests/testERP5Budget.py @@ -229,6 +229,10 @@ class TestBudget(ERP5TypeTestCase): portal_type='Account', financial_section='actif/actif_immobilise/immobilisations_financieres') + # Open accounts + for account in account_module.objectValues(portal_type='Account'): + account.validate() + # Create some accounting transactions self.accounting_transaction1 = accounting_module.newContent( portal_type='Accounting Transaction',title='Accounting 1', @@ -240,12 +244,12 @@ class TestBudget(ERP5TypeTestCase): portal_type='Accounting Transaction Line', source_section='organisation_module/world_company', resource='currency_module/EUR', source_debit='2000.0', - source_credit='0.0', source='account_module/account1') + source='account_module/account1') self.accounting_transaction1.newContent( portal_type='Accounting Transaction Line', source_section='organisation_module/world_company', - resource='currency_module/EUR', source_debit='0.0', - source_credit='2000.0', source='account_module/account2') + resource='currency_module/EUR', source_credit='2000.0', + source='account_module/account2') self.accounting_transaction2 = accounting_module.newContent( portal_type='Accounting Transaction',title='Accounting 2', @@ -257,12 +261,12 @@ class TestBudget(ERP5TypeTestCase): portal_type='Accounting Transaction Line', source_section='organisation_module/world_company', resource='currency_module/EUR', source_debit='100000.0', - source_credit='0.0', source='account_module/account1') + source='account_module/account1') self.accounting_transaction2.newContent( portal_type='Accounting Transaction Line', source_section='organisation_module/world_company', - resource='currency_module/EUR', source_debit='0.0', - source_credit='100000.0', source='account_module/account4') + resource='currency_module/EUR', source_credit='100000.0', + source='account_module/account4') id_list = [] for objects in self.accounting_transaction1.getPortalObject().\ -- 2.30.9