minor fixes in test cases
This commit is contained in:
parent
fd4bcd855b
commit
e2968e9893
@ -80,6 +80,8 @@ def create_purchase_order(**args):
|
||||
po.company = args.company or "_Test Company"
|
||||
po.supplier = args.customer or "_Test Supplier"
|
||||
po.is_subcontracted = args.is_subcontracted or "No"
|
||||
po.currency = args.currency or frappe.db.get_value("Company", po.company, "default_currency")
|
||||
po.conversion_factor = args.conversion_factor or 1
|
||||
|
||||
po.append("items", {
|
||||
"item_code": args.item or args.item_code or "_Test Item",
|
||||
|
@ -83,13 +83,13 @@ class TestStockEntry(unittest.TestCase):
|
||||
template = item
|
||||
|
||||
projected_qty, actual_qty = frappe.db.get_value("Bin", {"item_code": item_code,
|
||||
"warehouse": "_Test Warehouse - _TC"}, ["projected_qty", "actual_qty"]) or 0
|
||||
"warehouse": "_Test Warehouse - _TC"}, ["projected_qty", "actual_qty"]) or [0, 0]
|
||||
|
||||
# stock entry reqd for auto-reorder
|
||||
create_stock_reconciliation(item_code=item_code, warehouse="_Test Warehouse - _TC",
|
||||
qty = actual_qty + abs(projected_qty) + 10, rate=100)
|
||||
|
||||
projected_qty = projected_qty = frappe.db.get_value("Bin", {"item_code": item_code,
|
||||
projected_qty = frappe.db.get_value("Bin", {"item_code": item_code,
|
||||
"warehouse": "_Test Warehouse - _TC"}, "projected_qty") or 0
|
||||
|
||||
frappe.db.set_value("Stock Settings", None, "auto_indent", 1)
|
||||
|
Loading…
x
Reference in New Issue
Block a user