feat(spa): add top-level app-shell error boundary recover actions (#151)
All checks were successful
CI / test-and-quality (push) Successful in 1m56s
CI / test-and-quality (pull_request) Successful in 1m56s

This commit is contained in:
2026-03-01 10:42:09 +00:00
committed by Asger Geel Weirsoee
parent d6c7a36730
commit 2882a7737b
3 changed files with 49 additions and 5 deletions

View File

@@ -869,6 +869,14 @@ class UiScreenTests(TestCase):
self.assertContains(response, "hostShellRouteFromPath")
self.assertContains(response, "syncHostShellRoute")
self.assertContains(response, "Deep-link route guard: omdirigeret")
self.assertContains(response, "id=\"hostShellErrorBoundary\"")
self.assertContains(response, "recoverHostShell('retry')")
self.assertContains(response, "recoverHostShell('reload')")
self.assertContains(response, "setHostShellFatalError")
self.assertContains(response, "clearHostShellFatalError")
self.assertContains(response, "updateHostShellErrorBoundary")
self.assertContains(response, "host_shell_runtime_error")
self.assertContains(response, "window.addEventListener(\"unhandledrejection\"")
def test_host_screen_deeplink_requires_login(self):
response = self.client.get(reverse("lobby:host_screen_deeplink", kwargs={"spa_path": "guess"}))
@@ -956,6 +964,14 @@ class UiScreenTests(TestCase):
self.assertContains(response, "Session-data ikke opdateret endnu.")
self.assertContains(response, "Sidst opdateret:")
self.assertContains(response, "Session-data kan være forældet")
self.assertContains(response, "id=\"playerShellErrorBoundary\"")
self.assertContains(response, "recoverPlayerShell('retry')")
self.assertContains(response, "recoverPlayerShell('reload')")
self.assertContains(response, "setPlayerShellFatalError")
self.assertContains(response, "clearPlayerShellFatalError")
self.assertContains(response, "updatePlayerShellErrorBoundary")
self.assertContains(response, "player_shell_runtime_error")
self.assertContains(response, "window.addEventListener(\"error\"")
class SessionDetailRoundQuestionTests(TestCase):