* rfq2order2done - test case of process RFQ->confirm RFQ->Done RFQ. * generate_invoice_from_reception - test case of process to generate invoice on delivery of product. * run_scheduler - test case of process to run scheduler to generete RFQ from procurement. * merge_order - test case to merge orders * cancel_order - test case to cancel confirmed order, draft order * print_report - test case to generate report of RFQ and purchase order. * onchange_events - test case to test onchange_events like onchange_partner, onchange_warehouse, onchange_address * duplicate_order - test case to test duplicate order. * delete_order - test case to test delete confirmed order, draft order and canceled order. bzr revid: hmo@tinyerp.com-20111020072225-jq2r5x70z12a15o8
17 lines
929 B
YAML
17 lines
929 B
YAML
-
|
|
In order to test the PDF reports defined on a Purchase Order, I print a Request Quotation report
|
|
-
|
|
!python {model: purchase.order}: |
|
|
import netsvc, tools, os
|
|
(data, format) = netsvc.LocalService('report.purchase.quotation').create(cr, uid, [ref('purchase.order_purchase1'),ref('purchase.order_purchase2')], {}, {})
|
|
if tools.config['test_report_directory']:
|
|
file(os.path.join(tools.config['test_report_directory'], 'purchase-request_quotation'+format), 'wb+').write(data)
|
|
-
|
|
I print Purchase Order report
|
|
-
|
|
!python {model: purchase.order}: |
|
|
import netsvc, tools, os
|
|
(data, format) = netsvc.LocalService('report.purchase.order').create(cr, uid, [ref('purchase.order_purchase1'),ref('purchase.order_purchase2')], {}, {})
|
|
if tools.config['test_report_directory']:
|
|
file(os.path.join(tools.config['test_report_directory'], 'purchase-purchase_order_report'+format), 'wb+').write(data)
|