mirror of
https://github.com/anomalyco/opencode.git
synced 2026-11-20 01:08:31 +03:00
test: align status and shell expectations (#48906)
This commit is contained in:
committed by
GitHub
Unverified
parent
48c9a0a8de
commit
cd3a64b225
@@ -113,7 +113,7 @@ test("passes through non-event fetches", async ({ page }) => {
|
||||
return response.json()
|
||||
})
|
||||
|
||||
expect(health).toEqual({ version: "2.0.0", pid: 1, urls: ["http://localhost"] })
|
||||
expect(health).toEqual({ version: "2.0.0", pid: 1, urls: [] })
|
||||
await expect.poll(async () => (await timeline.transport.connections()).length).toBe(1)
|
||||
})
|
||||
|
||||
|
||||
@@ -96,7 +96,7 @@ test("single-server settings expose scoped pages without a server picker", async
|
||||
(request) => request.method() === "PATCH" && new URL(request.url()).pathname === "/api/experimental/config",
|
||||
)
|
||||
await page.getByRole("option", { name: "bash", exact: true }).click()
|
||||
expect((await updated).postDataJSON()).toEqual({ shell: "/bin/bash" })
|
||||
expect((await updated).postDataJSON()).toEqual({ shell: "bash" })
|
||||
})
|
||||
|
||||
test("project settings open as a nested autosaving view", async ({ page }) => {
|
||||
|
||||
@@ -180,7 +180,7 @@ try {
|
||||
"Packed workerd health returned " + response.status + ": " + await response.text(),
|
||||
)
|
||||
const body = await response.json()
|
||||
if (body.healthy !== true || body.version !== "packed-workerd") {
|
||||
if (body.version !== "packed-workerd" || body.pid !== 1 || !Array.isArray(body.urls)) {
|
||||
throw new Error("Unexpected packed workerd health: " + JSON.stringify(body))
|
||||
}
|
||||
} finally {
|
||||
|
||||
Reference in New Issue
Block a user