fix: Linting and test cases
diff --git a/erpnext/accounts/doctype/accounting_dimension/test_accounting_dimension.py b/erpnext/accounts/doctype/accounting_dimension/test_accounting_dimension.py
index b5375e1..fc1d7e3 100644
--- a/erpnext/accounts/doctype/accounting_dimension/test_accounting_dimension.py
+++ b/erpnext/accounts/doctype/accounting_dimension/test_accounting_dimension.py
@@ -75,14 +75,14 @@
frappe.set_user("Administrator")
if not frappe.db.exists("Accounting Dimension", {"document_type": "Department"}):
- dimension = frappe.get_doc({
+ frappe.get_doc({
"doctype": "Accounting Dimension",
"document_type": "Department",
}).insert()
else:
- dimension1 = frappe.get_doc("Accounting Dimension", "Department")
- dimension1.disabled = 0
- dimension1.save()
+ dimension = frappe.get_doc("Accounting Dimension", "Department")
+ dimension.disabled = 0
+ dimension.save()
if not frappe.db.exists("Accounting Dimension", {"document_type": "Location"}):
dimension1 = frappe.get_doc({
diff --git a/erpnext/accounts/doctype/accounting_dimension_filter/accounting_dimension_filter.js b/erpnext/accounts/doctype/accounting_dimension_filter/accounting_dimension_filter.js
index c8c32d5..994ee44 100644
--- a/erpnext/accounts/doctype/accounting_dimension_filter/accounting_dimension_filter.js
+++ b/erpnext/accounts/doctype/accounting_dimension_filter/accounting_dimension_filter.js
@@ -8,7 +8,7 @@
filters : {
'company': frm.doc.company
}
- }
+ };
});
frappe.db.get_list('Accounting Dimension',
@@ -41,7 +41,7 @@
frm.set_query('dimension_value', 'dimensions', function() {
return {
filters: filters
- }
+ };
});
}
});
diff --git a/erpnext/accounts/doctype/accounting_dimension_filter/test_accounting_dimension_filter.py b/erpnext/accounts/doctype/accounting_dimension_filter/test_accounting_dimension_filter.py
index feb0af1..02fd75e 100644
--- a/erpnext/accounts/doctype/accounting_dimension_filter/test_accounting_dimension_filter.py
+++ b/erpnext/accounts/doctype/accounting_dimension_filter/test_accounting_dimension_filter.py
@@ -10,6 +10,7 @@
class TestAccountingDimensionFilter(unittest.TestCase):
def setUp(self):
+ create_dimension()
create_accounting_dimension_filter()
def test_allowed_dimension_validation(self):
@@ -42,7 +43,7 @@
}],
'dimensions': [{
'accounting_dimension': 'Cost Center',
- 'dimension_value': '_Test Cost Center 3 - _TC'
+ 'dimension_value': '_Test Cost Center 2 - _TC'
}]
}).insert()
else: