From 3afdb39372dfbb96feace426938a07897844c2fe Mon Sep 17 00:00:00 2001 From: barredterra <14891507+barredterra@users.noreply.github.com> Date: Tue, 20 Dec 2022 15:30:15 +0100 Subject: [PATCH] fix: test update with content instead of title --- frappe/tests/test_frappe_client.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/frappe/tests/test_frappe_client.py b/frappe/tests/test_frappe_client.py index e80e43f49c..925d795ffe 100644 --- a/frappe/tests/test_frappe_client.py +++ b/frappe/tests/test_frappe_client.py @@ -105,16 +105,16 @@ class TestFrappeClient(FrappeTestCase): frappe.db.set_value("Website Settings", None, "title_prefix", "") def test_update_doc(self): - server = FrappeClient(get_url(), "Administrator", self.PASSWORD, verify=False) - frappe.db.delete("Note", {"title": ("in", ("Sing", "sing"))}) + server = FrappeClient(get_url(), "Administrator", "3zF2-89X4-AYSm-JA9M", verify=False) + frappe.db.delete("Note", {"title": "Sing"}) frappe.db.commit() - server.insert({"doctype": "Note", "public": True, "title": "Sing"}) + server.insert({"doctype": "Note", "title": "Sing"}) doc = server.get_doc("Note", "Sing") - changed_title = "sing" - doc["title"] = changed_title + new_content = "

Hello, World!

" + doc["content"] = new_content doc = server.update(doc) - self.assertTrue(doc["title"] == changed_title) + self.assertTrue(doc["content"] == new_content) def test_update_child_doc(self): server = FrappeClient(get_url(), "Administrator", self.PASSWORD, verify=False)