Compare commits

...

3 Commits

Author SHA1 Message Date
Gursheen Anand
ce4f4ff54a chore: fix linter 2024-02-26 17:46:32 +05:30
Gursheen Anand
ff0a109a13 fix: remove old ref links 2024-02-26 17:39:08 +05:30
Ankush Menat
96b3a83311 test: all dashboards
Prevent https://github.com/frappe/erpnext/pull/40005
2024-02-22 16:37:05 +05:30
5 changed files with 13 additions and 9 deletions

View File

@@ -8,6 +8,6 @@ def get_data():
{"label": _("Pre Sales"), "items": ["Quotation", "Supplier Quotation"]},
{"label": _("Sales"), "items": ["Sales Invoice", "Sales Order", "Delivery Note"]},
{"label": _("Purchase"), "items": ["Purchase Invoice", "Purchase Order", "Purchase Receipt"]},
{"label": _("Stock"), "items": ["Item Groups", "Item"]},
{"label": _("Stock"), "items": ["Item Group", "Item"]},
],
}

View File

@@ -53,12 +53,10 @@ class TestPaymentOrder(FrappeTestCase):
def create_payment_order_against_payment_entry(ref_doc, order_type, bank_account):
payment_order = frappe.get_doc(
dict(
doctype="Payment Order",
company="_Test Company",
payment_order_type=order_type,
company_bank_account=bank_account,
)
doctype="Payment Order",
company="_Test Company",
payment_order_type=order_type,
company_bank_account=bank_account,
)
doc = make_payment_order(ref_doc.name, payment_order)
doc.save()

View File

@@ -11,6 +11,6 @@ def get_data():
},
"transactions": [
{"label": _("Transactions"), "items": ["Sales Invoice", "Sales Order", "Delivery Note"]},
{"label": _("References"), "items": ["POS Profile", "Subscription", "Restaurant", "Tax Rule"]},
{"label": _("References"), "items": ["POS Profile", "Subscription", "Tax Rule"]},
],
}

View File

@@ -6,5 +6,5 @@ def get_data():
return {
"fieldname": "license_plate",
"non_standard_fieldnames": {"Delivery Trip": "vehicle"},
"transactions": [{"items": ["Vehicle Log"]}, {"items": ["Delivery Trip"]}],
"transactions": [{"items": ["Delivery Trip"]}],
}

View File

@@ -23,6 +23,7 @@ class TestFormLoads(FrappeTestCase):
with self.subTest(msg=f"Loading {doctype} - {last_doc}", doctype=doctype, last_doc=last_doc):
self.assertFormLoad(doctype, last_doc)
self.assertDocPrint(doctype, last_doc)
self.assertDashboardLoading(doctype, last_doc)
def assertFormLoad(self, doctype, docname):
# reset previous response
@@ -56,3 +57,8 @@ class TestFormLoads(FrappeTestCase):
# html should exist
self.assertTrue(bool(ret["html"]))
def assertDashboardLoading(self, doctype, docname):
from frappe.desk.notifications import get_open_count
self.assertTrue(get_open_count(doctype, docname))