mirror of
https://github.com/frappe/erpnext.git
synced 2026-06-05 13:24:47 +00:00
[tests] fixed for shopping cart
This commit is contained in:
@@ -10,6 +10,7 @@ from frappe.test_runner import make_test_records
|
||||
from erpnext.exceptions import PartyFrozen, PartyDisabled
|
||||
from frappe.utils import flt
|
||||
from erpnext.selling.doctype.customer.customer import get_credit_limit, get_customer_outstanding
|
||||
from erpnext.tests.utils import create_test_contact_and_address
|
||||
|
||||
test_ignore = ["Price List"]
|
||||
|
||||
@@ -47,31 +48,9 @@ class TestCustomer(unittest.TestCase):
|
||||
'customer_name': '_Test Customer'
|
||||
}
|
||||
|
||||
address = frappe.get_doc(dict(
|
||||
doctype='Address',
|
||||
address_title='_Test Address for Customer',
|
||||
address_type='Office',
|
||||
address_line1='Station Road',
|
||||
city='Mumbai',
|
||||
country='India',
|
||||
links = [dict(
|
||||
link_doctype='Customer',
|
||||
link_name='_Test Customer'
|
||||
)]
|
||||
)).insert()
|
||||
create_test_contact_and_address()
|
||||
|
||||
contact = frappe.get_doc(dict(
|
||||
doctype='Contact',
|
||||
email_id='test_contact_customer@example.com',
|
||||
phone='+91 0000000000',
|
||||
first_name='_Test Contact for _Test Customer',
|
||||
links = [dict(
|
||||
link_doctype='Customer',
|
||||
link_name='_Test Customer'
|
||||
)]
|
||||
)).insert()
|
||||
|
||||
frappe.db.set_value("Contact", "_Test Contact For _Test Customer-_Test Customer",
|
||||
frappe.db.set_value("Contact", "_Test Contact for _Test Customer-_Test Customer",
|
||||
"is_primary_contact", 1)
|
||||
|
||||
details = get_party_details("_Test Customer")
|
||||
|
||||
Reference in New Issue
Block a user