Skip to content

Evenfire is an intelligence layer platform for running LLM agents that take real actions, on your infrastructure

TypeScript

test(desktop-app): commit the document before reading the late-discovery view URL

Diego Zacarias4521083bbe2a
diff --git a/desktop-app/src/__tests__/appService.sandboxUiLifecycle.test.ts b/desktop-app/src/__tests__/appService.sandboxUiLifecycle.test.ts
index 86a60a6fa..dc7908347 100644
--- a/desktop-app/src/__tests__/appService.sandboxUiLifecycle.test.ts
+++ b/desktop-app/src/__tests__/appService.sandboxUiLifecycle.test.ts
@@ -295,7 +295,9 @@ describe('AppService sandbox-ui effective RPC endpoint', () => {
url: `${discoveredRpcUrl}/api/v1/sandbox-ui/sandbox-recipes/effective-app/`,
})
)
- expect(electronMocks.views.at(-1)?.webContents.currentUrl).toBe(
+ const { webContents } = electronMocks.views.at(-1)!
+ webContents.commitLoad()
+ expect(webContents.currentUrl).toBe(
`${discoveredRpcUrl}/api/v1/sandbox-ui/sandbox-recipes/effective-app/view/`
)
})