test: correct use of test decorator
This commit is contained in:
parent
95568210b2
commit
d3be84bfe8
@ -656,9 +656,8 @@ class TestItem(FrappeTestCase):
|
|||||||
make_stock_entry(qty=1, item_code=item.name, target="_Test Warehouse - _TC", posting_date = add_days(today(), 5))
|
make_stock_entry(qty=1, item_code=item.name, target="_Test Warehouse - _TC", posting_date = add_days(today(), 5))
|
||||||
self.consume_item_code_with_differet_stock_transactions(item_code=item.name)
|
self.consume_item_code_with_differet_stock_transactions(item_code=item.name)
|
||||||
|
|
||||||
@change_settings("Stock Settings", {"sample_retention_warehouse": 0})
|
@change_settings("Stock Settings", {"sample_retention_warehouse": "_Test Warehouse - _TC"})
|
||||||
def test_retain_sample(self):
|
def test_retain_sample(self):
|
||||||
frappe.db.set_single_value('Stock Settings', 'sample_retention_warehouse', '_Test Retain Sample Warehouse')
|
|
||||||
item = make_item("_TestRetainSample", {'has_batch_no': 1, 'retain_sample': 1, 'sample_quantity': 1})
|
item = make_item("_TestRetainSample", {'has_batch_no': 1, 'retain_sample': 1, 'sample_quantity': 1})
|
||||||
|
|
||||||
self.assertEqual(item.has_batch_no, 1)
|
self.assertEqual(item.has_batch_no, 1)
|
||||||
|
|||||||
@ -60,12 +60,5 @@
|
|||||||
"warehouse_name": "_Test Warehouse Group-C2",
|
"warehouse_name": "_Test Warehouse Group-C2",
|
||||||
"is_group": 0,
|
"is_group": 0,
|
||||||
"parent_warehouse": "_Test Warehouse Group - _TC"
|
"parent_warehouse": "_Test Warehouse Group - _TC"
|
||||||
},
|
|
||||||
{
|
|
||||||
"company": "_Test Company",
|
|
||||||
"doctype": "Warehouse",
|
|
||||||
"warehouse_name": "_Test Retain Sample Warehouse",
|
|
||||||
"parent_warehouse": "_Test Warehouse Group - _TC",
|
|
||||||
"is_group": 0
|
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user