diff --git a/lib/events/refresh.test.ts b/lib/events/refresh.test.ts index fbc3540..87bbb2c 100644 --- a/lib/events/refresh.test.ts +++ b/lib/events/refresh.test.ts @@ -14,16 +14,16 @@ describe("authoritative refresh scheduler", () => { const event = { type: "page.updated" as const, id: "page", version: 5 }; scheduler.connected(); - await vi.advanceTimersByTimeAsync(25); + vi.advanceTimersByTime(25); expect(refresh).toHaveBeenCalledTimes(1); scheduler.notified(event); scheduler.notified(event); - await vi.advanceTimersByTimeAsync(25); + vi.advanceTimersByTime(25); expect(refresh).toHaveBeenCalledTimes(2); scheduler.connected(); - await vi.advanceTimersByTimeAsync(25); + vi.advanceTimersByTime(25); expect(refresh).toHaveBeenCalledTimes(3); scheduler.dispose(); }); diff --git a/lib/events/sse.test.ts b/lib/events/sse.test.ts index c39ed27..9d28d21 100644 --- a/lib/events/sse.test.ts +++ b/lib/events/sse.test.ts @@ -42,9 +42,9 @@ describe("SSE stream", () => { expect(decoder.decode((await reader.read()).value)).toBe( "event: deployment\ndata: release-2\n\n", ); - await vi.advanceTimersByTimeAsync(50); + vi.advanceTimersByTime(50); expect(decoder.decode((await reader.read()).value)).toMatch(/^: heartbeat /u); - await vi.advanceTimersByTimeAsync(49); + vi.advanceTimersByTime(49); expect((await reader.read()).done).toBe(true); expect(onClose).toHaveBeenCalledTimes(1); }); diff --git a/lib/health/readiness.test.ts b/lib/health/readiness.test.ts index c675af1..65dce91 100644 --- a/lib/health/readiness.test.ts +++ b/lib/health/readiness.test.ts @@ -30,7 +30,7 @@ describe("readiness checks", () => { { database: () => new Promise(() => undefined) }, 100, ); - await vi.advanceTimersByTimeAsync(100); + vi.advanceTimersByTime(100); await expect(result).resolves.toEqual({ status: "not-ready", checks: { database: "failed" }, diff --git a/tests/deployment-contract.test.ts b/tests/deployment-contract.test.ts index 179c3bc..7d63a17 100644 --- a/tests/deployment-contract.test.ts +++ b/tests/deployment-contract.test.ts @@ -98,9 +98,10 @@ describe("production deployment contract", () => { expect(workflow).toContain("bun run typecheck"); expect(workflow).toContain("bun run lint"); expect(workflow).toContain("kubectl kustomize k8s/"); - expect(workflow).toContain("target: app"); - expect(workflow).toContain("target: migration"); - expect(workflow.match(/platforms: linux\/arm64/gmu)).toHaveLength(2); + expect(workflow).toContain("--target app"); + expect(workflow).toContain("--target migration"); + expect(workflow).not.toContain("platforms: linux/arm64"); + expect(workflow).not.toMatch(/docker\/setup-qemu-action|docker\/setup-buildx-action|docker\/login-action/iu); expect(workflow).toContain( "registry.neko-piranha.ts.net/astral/buzz-sheet", );