test: tighten gateway health auth assertions

This commit is contained in:
Peter Steinberger
2026-05-08 15:02:20 +01:00
parent 5c39e2da3a
commit 7d20be5fb5
2 changed files with 2 additions and 2 deletions

View File

@@ -217,7 +217,7 @@ describe("gateway auth compatibility baseline", () => {
});
expect(rotated.ok).toBe(true);
const rotatedToken = rotated.ok ? rotated.entry.token : "";
expect(rotatedToken).toEqual(expect.any(String));
expect(rotatedToken).toBeTypeOf("string");
expect(rotatedToken.length).toBeGreaterThan(0);
const ws = await openWs(port);

View File

@@ -167,7 +167,7 @@ describe("gateway server health/presence", () => {
await localHarness.close();
const evt = await shutdownP;
const evtPayload = evt.payload as { reason?: unknown } | undefined;
expect(evtPayload?.reason).toEqual(expect.any(String));
expect(evtPayload?.reason).toBe("gateway stopping");
});
test(