sale_unit_test.xml not loaded

Bug #513367 reported by Numérigraphe
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Odoo Addons (MOVED TO GITHUB)
Fix Released
Undecided
Ravi Gadhia (OpenERP)
Nominated for 5.0 by Numérigraphe
Nominated for Trunk by Numérigraphe

Bug Description

In the bzr there's a file sale/sale_unit_test.xml but it's not referenced to in the __terp__.py (nor anywhere else for that matter).
If someone wrote a test, why not run it ?
Lionel

Related branches

Revision history for this message
Numérigraphe (numerigraphe) wrote :

Oh well this test file must be obsolete. I think it's trying to pay the invoice using an account of type "cash" but there's no such account type. "cash" is for journals.
I'll try to make something out of this.
Lionel

Revision history for this message
Numérigraphe (numerigraphe) wrote :

Here's a patch to fix the unit test and add it to the demo dataset (it can't be run in init or update because it uses demo data).

Husen Daudi (husendaudi)
Changed in openobject-addons:
assignee: nobody → RGA(Open ERP) (rga-openerp)
Revision history for this message
Numérigraphe (numerigraphe) wrote :

FYI I improved this test a bit in the branch lp:~numerigraphe/openobject-addons/unittest-5.0, along with another test I wrote to check invoice from the packings.
Feel free to merge this branch as/if if you fit. I'll be writing some more tests in the next days.
Lionel.

Revision history for this message
Numérigraphe (numerigraphe) wrote :

By the way, the test picks arbitrary an partener and address, which turns out to be the company itself.
I suggest it be changed to:
        <record id="test_order_1" model="sale.order">
            <field name="client_order_ref">test_order_1</field>
            <field name="note">This Sale Order was used to test the following use case during the installation: Order - Invoice - Payment - Picking</field>
            <field name="shop_id" ref="shop" />
            <field model="product.pricelist" name="pricelist_id" search="[]" />
            <field name="user_id" ref="base.user_root" />
            <field name="partner_id" ref="base.res_partner_agrolait" />
            <field name="partner_invoice_id" ref="base.res_partner_address_8" />
            <field name="partner_shipping_id" ref="base.res_partner_address_8" />
            <field name="partner_order_id" ref="base.res_partner_address_8" />
        </record>

Having a distinct delivery and invoice address would be even better but needs patching the base module demo data set in the server.
I'll file another bug for this.
Lionel

Changed in openobject-addons:
status: New → Fix Committed
Revision history for this message
Numérigraphe (numerigraphe) wrote :

Do you mind if I set this as "fix committed" to show that I have a fix a branch of mine ?
Lionel

Changed in openobject-addons:
status: Fix Committed → Fix Released
Revision history for this message
Numérigraphe (numerigraphe) wrote :

Fixed by Olivier Dony in <email address hidden>, but he forgot to mention it - naughty boy.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.