test: align qdrant ollama verification fixtures

This commit is contained in:
2026-08-08 22:15:02 +02:00
parent ffe0afb6a7
commit 4e810af516
11 changed files with 72 additions and 44 deletions
+8 -4
View File
@@ -269,15 +269,19 @@ test("runs the injected installation diagnostic for a migration-required v2 work
}
});
test("fails closed for /workspaces/:id/test on a schema v3 workspace before the internal runtime lands", async () => {
test("runs diagnostics for a schema v3 workspace without external semantic bindings", async () => {
const diagnose = vi.fn(async () => ({ activatable: true, diagnostics: [] }));
const app = appFor(registryFake(), diagnose);
const testResult = await app.inject({ method: "POST", url: "/workspaces/psd-clinical/test", payload: {} });
expect(testResult.statusCode).toBe(400);
expect(testResult.json()).toMatchObject({ code: "workspace_invalid" });
expect(diagnose).not.toHaveBeenCalled();
expect(testResult.statusCode).toBe(200);
expect(testResult.json()).toMatchObject({ activatable: true, diagnostics: [] });
expect(diagnose).toHaveBeenCalledWith(workspace, expect.objectContaining({
vector: expect.objectContaining({ missing: [], values: {} }),
vectorWriter: expect.objectContaining({ missing: [], values: {} }),
embedding: expect.objectContaining({ missing: [], values: {} }),
}), { writeProbe: false });
});
test("returns a 409 field conflict instead of overwriting a changed workspace", async () => {