Skip to content

Open-source Grok Bot alternative with a virtual machine that bots can use

Assert the About me switch is actually unchecked

CI fixturee3e6bd98d533
diff --git a/src/components/bot-settings/MemorySection.test.ts b/src/components/bot-settings/MemorySection.test.ts
index 624ded55e1..35ff31f1b3 100644
--- a/src/components/bot-settings/MemorySection.test.ts
+++ b/src/components/bot-settings/MemorySection.test.ts
@@ -180,7 +180,7 @@ describe("MemoryUpkeepCard", () => {
expect(on).toContain("this bot still keeps its own notes and tidies them");
expect(on).toContain('aria-label="Learn facts into About me"');
const unchecked = render(createElement(MemoryUpkeepCard, { enabled: true, status: null, tidying: false, onToggle: noop, onTidy: noop, aboutMe: { ...aboutMe, enabled: false } }));
- expect(unchecked).not.toContain('aria-checked="true" aria-label="Learn facts into About me"');
+ expect(unchecked).toMatch(/<button(?=[^>]*aria-label="Learn facts into About me")(?=[^>]*aria-checked="false")[^>]*>/);
const off = render(createElement(MemoryUpkeepCard, { enabled: false, status: null, tidying: false, onToggle: noop, onTidy: noop, aboutMe }));
expect(off).not.toContain("Learn facts into About me");
});