Refresh HiveGrid Cloud reference snapshot
This commit is contained in:
1 parent
5e99e14772
commit
7f88026f79
5955 files changed
+1177325
-188362
No files matched your search
+1
-1
@@ -103,7 +103,7 @@ describe("admin API route isolation", () => {
|
||||
expect(mocks.getAllApiKeys).toHaveBeenCalledWith();
|
||||
expect(mocks.getAllApiKeys.mock.calls[0]).toHaveLength(0);
|
||||
expect(data).toEqual({ apiKeys: [tenantAApiKey, tenantBApiKey] });
|
||||
});
|
||||
}, 60_000);
|
||||
|
||||
it("skips cross-tenant API-key access when admin permission is denied", async () => {
|
||||
const denied = Object.assign(new Error("admin.apiKeys.view denied"), { status: 403 });
|
||||
|
||||
+25
@@ -0,0 +1,25 @@
|
||||
import { describe, expect, it } from "vitest";
|
||||
|
||||
describe("Request realm compatibility", () => {
|
||||
it("accepts realm-local URLSearchParams bodies and preserves form parsing", async () => {
|
||||
const request = new Request("https://app.example.test/action", {
|
||||
method: "POST",
|
||||
body: new URLSearchParams({ action: "save", id: "record_1" }),
|
||||
});
|
||||
|
||||
expect(request.headers.get("content-type")).toBe("application/x-www-form-urlencoded;charset=UTF-8");
|
||||
const formData = await request.formData();
|
||||
expect(Object.fromEntries(formData)).toEqual({ action: "save", id: "record_1" });
|
||||
});
|
||||
|
||||
it("accepts a jsdom AbortSignal when native Request uses a different realm", () => {
|
||||
const controller = new window.AbortController();
|
||||
|
||||
expect(
|
||||
() =>
|
||||
new Request("https://app.example.test/navigation", {
|
||||
signal: controller.signal,
|
||||
}),
|
||||
).not.toThrow();
|
||||
});
|
||||
});
|
||||
Reference in new issue
Block a user