ci: trigga på master + formatfix inför Gitea Actions
CI / Typecheck, test & build (push) Failing after 2s

This commit is contained in:
Sven (AAMOS AI)
2026-08-13 17:25:14 +07:00
parent 61d60931ad
commit c32a7e33c7
141 changed files with 40555 additions and 45210 deletions
+25 -11
View File
@@ -38,9 +38,7 @@ describe("buildMemoryOverview", () => {
});
it("visar origin och confidence tydligt", () => {
const items: MemoryItem[] = [
makeItem({ origin: "observed", confidence: 0.75 }),
];
const items: MemoryItem[] = [makeItem({ origin: "observed", confidence: 0.75 })];
const overview = buildMemoryOverview(items, "sv-SE");
const item = overview.sections[0]!.items[0]!;
expect(item.originLabel).toBe("Vi har sett");
@@ -83,12 +81,24 @@ describe("buildMemoryOverview", () => {
});
it("renderMemorySummary stödjer S5-value-former", () => {
expect(renderMemorySummary({ summarySv: "", value: { favoriteCuisine: "thai" } }, "en-US")).toBe("Favorite cuisine: thai");
expect(renderMemorySummary({ summarySv: "", value: { avoidIngredientId: "broccoli" } }, "en-US")).toBe("Avoids ingredient: broccoli");
expect(renderMemorySummary({ summarySv: "", value: { goal: "less_waste" } }, "en-US")).toBe("Goal: less_waste");
expect(renderMemorySummary({ summarySv: "", value: { primaryGoal: "less_waste" } }, "en-US")).toBe("Primary goal: less_waste");
expect(renderMemorySummary({ summarySv: "", value: { allergen: "gluten" } }, "en-US")).toBe("Allergy: gluten");
expect(renderMemorySummary({ summarySv: "", value: { spiceLevelMax: 2 } }, "en-US")).toBe("Max spice level: 2");
expect(
renderMemorySummary({ summarySv: "", value: { favoriteCuisine: "thai" } }, "en-US"),
).toBe("Favorite cuisine: thai");
expect(
renderMemorySummary({ summarySv: "", value: { avoidIngredientId: "broccoli" } }, "en-US"),
).toBe("Avoids ingredient: broccoli");
expect(renderMemorySummary({ summarySv: "", value: { goal: "less_waste" } }, "en-US")).toBe(
"Goal: less_waste",
);
expect(
renderMemorySummary({ summarySv: "", value: { primaryGoal: "less_waste" } }, "en-US"),
).toBe("Primary goal: less_waste");
expect(renderMemorySummary({ summarySv: "", value: { allergen: "gluten" } }, "en-US")).toBe(
"Allergy: gluten",
);
expect(renderMemorySummary({ summarySv: "", value: { spiceLevelMax: 2 } }, "en-US")).toBe(
"Max spice level: 2",
);
});
});
@@ -131,7 +141,9 @@ describe("deriveMemoryUpdates", () => {
const result = await deriveMemoryUpdates(aamos, {
scope: "user",
scopeId: "u1",
events: [{ id: "evt-real", type: "recipe_cooked", occurredAt: "2026-08-01T12:00:00Z", payload: {} }],
events: [
{ id: "evt-real", type: "recipe_cooked", occurredAt: "2026-08-01T12:00:00Z", payload: {} },
],
existingMemoryKeys: [],
consentFlags: { personalization: true, anonymizedImprovement: false, imageTraining: false },
});
@@ -156,7 +168,9 @@ describe("deriveMemoryUpdates", () => {
const result = await deriveMemoryUpdates(aamos, {
scope: "user",
scopeId: "u1",
events: [{ id: "evt-real", type: "recipe_cooked", occurredAt: "2026-08-01T12:00:00Z", payload: {} }],
events: [
{ id: "evt-real", type: "recipe_cooked", occurredAt: "2026-08-01T12:00:00Z", payload: {} },
],
existingMemoryKeys: [],
consentFlags: { personalization: true, anonymizedImprovement: false, imageTraining: false },
});