odoo/addons/purchase/test/process/run_scheduler.yml

27 lines
776 B
YAML

-
In order to test the scheduler to generate RFQ.
-
I create a procurement order.
-
!record {model: procurement.order, id: procurement_order_testcase0}:
location_id: stock.stock_location_stock
name: Test scheduler for RFQ
procure_method: make_to_order
product_id: product.product_product_45
product_qty: 15.0
-
I confirm on procurement order.
-
!workflow {model: procurement.order, action: button_confirm, ref: procurement_order_testcase0}
-
I run the scheduler.
-
!python {model: procurement.order}: |
self.run_scheduler(cr, uid)
-
I check Generated RFQ.
-
!python {model: procurement.order}: |
procurement = self.browse(cr, uid, ref('procurement_order_testcase0'))
assert procurement.purchase_id, 'RFQ should be generated!'