[IMP] improved the yml of mrp_subproduct
authorBharat Devnani (OpenERP) <bde@tinyerp.com>
Tue, 24 Jul 2012 13:02:51 +0000 (18:32 +0530)
committerBharat Devnani (OpenERP) <bde@tinyerp.com>
Tue, 24 Jul 2012 13:02:51 +0000 (18:32 +0530)
bzr revid: bde@tinyerp.com-20120724130251-vuyee33s7yy26pll

addons/mrp_subproduct/test/mrp_subproduct.yml

index 36b5f44..99da9f2 100644 (file)
@@ -4,7 +4,7 @@
 -
   I add a sub product in Bill of material for product External Hard Disk.
 -
-  !record {model: mrp.bom, id: mrp_bom_arm1}:
+  !record {model: mrp.bom, id: mrp.mrp_bom_24}:
     product_id: product.product_product_28
     name: External Hard Disk + Subproduct
     product_uom: product.product_uom_unit
@@ -18,9 +18,9 @@
 -
   !record {model: mrp.production, id: mrp_production_mo0}:
     product_id: product.product_product_28
-    product_qty: 10.0
+    product_qty: 2.0
     product_uom: product.product_uom_unit
-    bom_id: mrp_bom_arm1
+    bom_id: mrp.mrp_bom_24
     location_src_id: stock.stock_location_stock
 -
   I compute the data of production order.
@@ -30,8 +30,7 @@
 -
   I confirm the production order.
 -
-  !python {model: mrp.production}: |
-    self.action_confirm(cr, uid, [ref('mrp_production_mo0')])
+    !workflow {model: mrp.production, action: button_confirm, ref: mrp_production_mo0}
 -
   I check production order state.
 -
@@ -59,7 +58,7 @@
   I create record for selecting mode and quantity of products to produce.
 -
   !record {model: mrp.product.produce, id: mrp_product_produce0}:
-    product_qty: 10.00
+    product_qty: 2.00
     mode: 'consume_produce'
 -
   I finish the production order.