Merge lp:~donkirkby/openobject-addons/purchase-tests into lp:openobject-addons/5.0

Proposed by Don Kirkby
Status: Merged
Merged at revision: not available
Proposed branch: lp:~donkirkby/openobject-addons/purchase-tests
Merge into: lp:openobject-addons/5.0
Diff against target: 38 lines (+4/-4)
2 files modified
purchase/__terp__.py (+1/-1)
purchase/purchase_unit_test.xml (+3/-3)
To merge this branch: bzr merge lp:~donkirkby/openobject-addons/purchase-tests
Reviewer Review Type Date Requested Status
Olivier Dony (Odoo) Approve
Christophe Simonis (OpenERP) Approve
Review via email: mp+20686@code.launchpad.net

Description of the change

Fixes bug lp:532073 to add the purchase module's unit tests back in. vra gave me a patch to get the tests passing again. I also tweaked the location the a purchase order so that it leaves the demo data in a more logical state.

To post a comment you must log in.
Revision history for this message
Christophe Simonis (OpenERP) (kangol) :
review: Approve
Revision history for this message
Olivier Dony (Odoo) (odo-openerp) :
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'purchase/__terp__.py'
--- purchase/__terp__.py 2009-02-03 17:02:20 +0000
+++ purchase/__terp__.py 2010-03-04 19:18:21 +0000
@@ -44,7 +44,7 @@
44 'partner_view.xml',44 'partner_view.xml',
45 'process/purchase_process.xml'45 'process/purchase_process.xml'
46 ],46 ],
47 'demo_xml': ['purchase_demo.xml'],47 'demo_xml': ['purchase_demo.xml', 'purchase_unit_test.xml'],
48 'installable': True,48 'installable': True,
49 'active': False,49 'active': False,
50 'certificate': '0057234283549',50 'certificate': '0057234283549',
5151
=== modified file 'purchase/purchase_unit_test.xml'
--- purchase/purchase_unit_test.xml 2008-09-10 17:56:00 +0000
+++ purchase/purchase_unit_test.xml 2010-03-04 19:18:21 +0000
@@ -28,7 +28,7 @@
28 <field name="pricelist_id" ref="list0"/>28 <field name="pricelist_id" ref="list0"/>
29 <field name="partner_id" search="[]" model="res.partner"/>29 <field name="partner_id" search="[]" model="res.partner"/>
30 <field name="partner_address_id" search="[]" model="res.partner.address"/>30 <field name="partner_address_id" search="[]" model="res.partner.address"/>
31 <field name="location_id" search="[]" model="stock.location"/>31 <field name="location_id" ref="stock.stock_location_stock"/>
32 </record>32 </record>
33 <!-- Resource: purchase.order.line -->33 <!-- Resource: purchase.order.line -->
34 <!--34 <!--
@@ -99,10 +99,10 @@
99 <function model="account.invoice" name="pay_and_reconcile">99 <function model="account.invoice" name="pay_and_reconcile">
100 <value model="purchase.order" eval="[obj(ref('test_purchase_1')).invoice_id.id]" />100 <value model="purchase.order" eval="[obj(ref('test_purchase_1')).invoice_id.id]" />
101 <value eval="1164" />101 <value eval="1164" />
102 <value search="[('type', '=', 'cash')]" model="account.account"/>102 <value eval="ref('account.cash')"/>
103 <value eval="ref('account.period_' + str(int(time.strftime('%m'))))" />103 <value eval="ref('account.period_' + str(int(time.strftime('%m'))))" />
104 <value eval="ref('account.bank_journal')" />104 <value eval="ref('account.bank_journal')" />
105 <value search="[('type', '=', 'cash')]" model="account.account"/>105 <value eval="ref('account.cash')"/>
106 <value eval="ref('account.period_' + str(int(time.strftime('%m'))))" />106 <value eval="ref('account.period_' + str(int(time.strftime('%m'))))" />
107 <value eval="ref('account.bank_journal')" />107 <value eval="ref('account.bank_journal')" />
108 </function>108 </function>