Skip to content

Commit

Permalink
fix: enable fetch_timesheet_in_sales_invoice in test
Browse files Browse the repository at this point in the history
(cherry picked from commit 5880f1d)

# Conflicts:
#	erpnext/projects/doctype/timesheet/test_timesheet.py
  • Loading branch information
venkat102 authored and mergify[bot] committed Feb 25, 2025
1 parent 97d3e86 commit feb64cb
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions erpnext/projects/doctype/timesheet/test_timesheet.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@ def test_sales_invoice_from_timesheet(self):
self.assertEqual(item.qty, 2.00)
self.assertEqual(item.rate, 50.00)

@IntegrationTestCase.change_settings("Projects Settings", {"fetch_timesheet_in_sales_invoice": 1})
def test_timesheet_billing_based_on_project(self):
emp = make_employee("test_employee_6@salary.com")
project = frappe.get_value("Project", {"project_name": "_Test Project"})
Expand All @@ -62,6 +63,10 @@ def test_timesheet_billing_based_on_project(self):
)
sales_invoice = create_sales_invoice(do_not_save=True)
sales_invoice.project = project
<<<<<<< HEAD
=======
sales_invoice.add_timesheet_data()
>>>>>>> 5880f1d5c6 (fix: enable fetch_timesheet_in_sales_invoice in test)
sales_invoice.submit()

ts = frappe.get_doc("Timesheet", timesheet.name)
Expand Down

0 comments on commit feb64cb

Please sign in to comment.