<commit_before>-
  For test the procurement module, First I have to check current product quantity.
-
  !python {model: product.product}: |
    product = self.browse(cr, uid, ref('product.product_product_cpu2'))
    assert product.virtual_available < 5.0,'Virtual stock have more quantities. so, not possible to check minimum stock rule process'
-
  I create minimum stock rule for product CPU2.
-
  !record {model: stock.warehouse.orderpoint, id: stock_warehouse_orderpoint_op0}:
    company_id: base.main_company
    location_id: stock.stock_location_stock
    logic: max
    name: OP/00008
    product_id: product.product_product_cpu2    
    product_max_qty: 15.0
    product_min_qty: 5.0
    product_uom: product.product_uom_kgm
    qty_multiple: 1
    warehouse_id: stock.warehouse0
-
  I run the scheduler.
-
  !python {model: procurement.order}: |
    self.run_scheduler(cr, uid)

<commit_msg>[IMP]procurement: Improve test cases<commit_after>-
  For test the procurement module, First I have to check current product quantity.
-
  !python {model: product.product}: |
    product = self.browse(cr, uid, ref('product.product_product_cpu2'))
    assert product.virtual_available < 5.0,'Virtual stock have more quantities. so, not possible to check minimum stock rule process'
-
  I create minimum stock rule for product CPU2.
-
  !record {model: stock.warehouse.orderpoint, id: stock_warehouse_orderpoint_op0}:
    company_id: base.main_company
    location_id: stock.stock_location_stock
    logic: max
    name: OP/00008
    product_id: product.product_product_cpu2    
    product_max_qty: 15.0
    product_min_qty: 5.0
    product_uom: product.product_uom_kgm
    qty_multiple: 1
    warehouse_id: stock.warehouse0
-
  I run the scheduler.
-
  !python {model: procurement.order}: |
    self.run_scheduler(cr, uid)
-
  I check that procurement order created.
-
  !python {model: procurement.order}: |
    proc_ids = self.search(cr, uid, [('product_id','=', ref('product.product_product_cpu2'))])
    assert proc_ids, 'No Procurement created.'
    proc_order = self.browse(cr, uid, proc_ids)
    assert proc_order[0].product_qty == 15.0,"Procurement order is not corresponded to product quantities"
-
  I check product quantity.
-
  !python {model: product.product}: |
    product = self.browse(cr, uid, ref('product.product_product_cpu2'))
    assert product.virtual_available >= 5.0,"After run the scheduler the product virtual stock still not update as specified in stock rule"

{'fraction_non_alphanumeric': 0.094817195660908, 'fraction_numerical': 0.017677782241864202, 'mean_word_length': 4.040485829959514, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 4, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7472577', 'n_tokens_mistral': 822, 'n_tokens_neox': 782, 'n_words': 223}