Update hivegrid-cloud reference to latest main

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
davidandClaude Fable 5 committed 2026-07-08 16:15:37 +02:00
1 parent e98d38e716
commit 7b21524c86
3781 files changed
+373484 -225607

No files matched your search

@@ -52,7 +52,7 @@ const limiterDecision = { allowed: true, remaining: 9, oldestAt: null };
vi.mock("~/shared-store.server", () => ({
getSharedStore: () => ({}),
}));
vi.mock("@toolctrl/shared-store", async (orig) => {
vi.mock("@hivegrid/shared-store", async (orig) => {
const real = (await orig()) as Record<string, unknown>;
return {
...real,
@@ -80,7 +80,9 @@ function makeRequest(body: unknown, origin: string | null, opts: { ip?: string;
headers: {
"content-type": "application/json",
...(origin ? { origin } : {}),
"x-forwarded-for": opts.ip ?? "1.2.3.4",
// Trusted proxy-set header — the endpoint no longer keys the per-IP
// limiter on the client-spoofable X-Forwarded-For.
"cf-connecting-ip": opts.ip ?? "1.2.3.4",
"user-agent": "vitest",
},
});
@@ -91,7 +93,7 @@ describe("api.leads.capture action", () => {
captureLeadMock.mockClear();
evaluateFlagMock.mockClear();
getTranslationsMock.mockClear();
process.env.MARKETING_ALLOWED_ORIGINS = "https://marketing.example.com,https://*.toolctrl.de";
process.env.MARKETING_ALLOWED_ORIGINS = "https://marketing.example.com,https://*.hivegrid.de";
delete process.env.MCAPTCHA_INSTANCE_URL;
delete process.env.MCAPTCHA_ACCOUNT_SECRET;
delete process.env.MCAPTCHA_SITEKEY_FORMS;
@@ -133,7 +135,7 @@ describe("api.leads.capture action", () => {
it("accepts wildcard subdomain", async () => {
const action = await loadAction();
const res = await action({
request: makeRequest({ email: "a@b.co" }, "https://landing.toolctrl.de"),
request: makeRequest({ email: "a@b.co" }, "https://landing.hivegrid.de"),
});
expect(res.status).toBe(200);
expect(captureLeadMock).toHaveBeenCalledTimes(1);