From 8c69bfeee939069129020bb37f4eddef50b74de9 Mon Sep 17 00:00:00 2001 From: ai-bot Date: Tue, 13 Oct 2026 15:43:06 +0000 Subject: [PATCH] tests: match the health and login paths exactly in the service worker test --- tests/test_pwa.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/tests/test_pwa.py b/tests/test_pwa.py index 173de58..74dd64e 100644 --- a/tests/test_pwa.py +++ b/tests/test_pwa.py @@ -50,8 +50,10 @@ class ServiceWorkerTests(unittest.TestCase): body = self.read_static("sw.js") self.assertNotIn("/api/", body) - self.assertNotIn("/health", body) - self.assertNotIn("/login", body) + # The quoted path is what matters: "/health-check" is a shell path, while + # "/health" and "/login" are not, and must not appear. + self.assertNotIn('"/health"', body) + self.assertNotIn('"/login"', body) # The shell it does cache is the five pages and their assets. for path in ("/", "/setup", "/settings", "/health-check", "/history", "/styles.css"): self.assertIn(f'"{path}"', body)