[bean] [mandatory] fixes in test cases

This commit is contained in:
Anand Doshi
2013-07-08 18:50:45 +05:30
parent 2862c9e1df
commit 4ee647e84c
20 changed files with 75 additions and 33 deletions

View File

@@ -12,5 +12,6 @@ test_records = [
"income_account": "Sales - _TC",
"cost_center": "_Test Cost Center - _TC",
"expense_account": "_Test Account Cost for Goods Sold - _TC",
"naming_series": "_T-Sales Invoice-"
}]
]

View File

@@ -366,6 +366,7 @@ test_records = [
# parent
{
"doctype": "Purchase Invoice",
"naming_series": "_T-Purchase Invoice-",
"supplier_name": "_Test Supplier",
"credit_to": "_Test Supplier - _TC",
"bill_no": "NA",

View File

@@ -423,6 +423,7 @@ class TestSalesInvoice(unittest.TestCase):
from stock.doctype.purchase_receipt.test_purchase_receipt import test_records \
as pr_test_records
pr = webnotes.bean(copy=pr_test_records[0])
pr.doc.naming_series = "_T-Purchase Receipt-"
pr.run_method("calculate_taxes_and_totals")
pr.insert()
pr.submit()
@@ -431,6 +432,7 @@ class TestSalesInvoice(unittest.TestCase):
from stock.doctype.delivery_note.test_delivery_note import test_records \
as dn_test_records
dn = webnotes.bean(copy=dn_test_records[0])
dn.doc.naming_series = "_T-Delivery Note-"
dn.insert()
dn.submit()
return dn

View File

@@ -32,6 +32,7 @@ test_records = [
[
{
"doctype": "Shipping Rule",
"label": "_Test Shipping Rule",
"calculate_based_on": "Net Total",
"company": "_Test Company",
"account": "_Test Account Shipping Charges - _TC",