Skip to content

Self-hosted, Self-Improving, Federated Everything App — dev management, agent orchestration, persistent mind, digital twin, second brain, and creative pipeline from a single dashboard over Tailscale to port the user into the OS

address review (ollama): assert the closed-drawer fetch gate directly

Adam Eivy54a7a24575d1
diff --git a/client/src/components/creative-director/CreativeDirectorModelsDrawer.test.jsx b/client/src/components/creative-director/CreativeDirectorModelsDrawer.test.jsx
index c2bc690072..f81980dba6 100644
--- a/client/src/components/creative-director/CreativeDirectorModelsDrawer.test.jsx
+++ b/client/src/components/creative-director/CreativeDirectorModelsDrawer.test.jsx
@@ -141,8 +141,12 @@ describe('CreativeDirectorModelsDrawer', () => {
<CreativeDirectorModelsDrawer open={false} onClose={vi.fn()} project={{ id: 'cd-1', name: 'Demo' }} />
</MemoryRouter>,
);
- await waitFor(() => expect(getAiAssignments).not.toHaveBeenCalled());
+ // Assert directly rather than through waitFor: `render` already flushes
+ // effects inside act(), so both fetches would have fired by now if ungated.
+ // A `waitFor` wrapping a `.not` assertion resolves on its first check and
+ // would pass whether or not the effect ever ran.
expect(getVisionModels).not.toHaveBeenCalled();
+ expect(getAiAssignments).not.toHaveBeenCalled();
});
// /vision-models also returns `backend:'cli'` rows, and those are a blanket