deploy ProspectOS workspace v8 final

This commit is contained in:
Marco0300
2026-09-08 13:51:35 +02:00
parent b9ef1e4dc7
commit 9db943d5df
4 changed files with 113 additions and 30 deletions
+14
View File
@@ -384,6 +384,20 @@ class BrowserOnlyAppTests(unittest.TestCase):
self.assertIn("does not show a website", text)
self.assertIn("Kind regards", text)
def test_message_strategy_uses_concise_greeting_and_missing_site_shape(self):
prospect = {
"id": 7,
"name": "Ash Electrical Cape Town",
"address": "Salt River, Cape Town",
"search_category": "Electricians",
"website_status": "no_detected_website",
}
self.assertEqual(server._message_display_name(prospect), "Ash Electrical")
strategy = server._message_strategy_context(prospect)
self.assertEqual(strategy["business_name_for_greeting"], "Ash Electrical")
self.assertIn("looking at local Electricians in Cape Town", strategy["preferred_message_shape"])
self.assertIn("dedicated website", strategy["preferred_message_shape"])
def test_email_draft_can_include_latest_mockup_link(self):
conn = server.db()
conn.execute("INSERT INTO prospects(name,domain,category,discovered_at) VALUES(?,?,?,?)", ("Acme", "maps:acme", "plumber", server.now()))