feat: add foreign key constraints and metrics for blockchain node

This commit is contained in:
oib
2025-09-28 06:04:30 +02:00
parent fe29631a86
commit b8b640666d
188 changed files with 15678 additions and 158 deletions

View File

@@ -0,0 +1,23 @@
import { describe, expect, it } from "vitest";
import { AitbcClient } from "./client";
const createClient = () =>
new AitbcClient({
baseUrl: "https://api.example.com",
apiKey: "test-key",
fetchImpl: async (input: RequestInfo | URL, init?: RequestInit) =>
new Response(JSON.stringify({ job_id: "job", candidates: [] }), {
status: 200,
headers: { "Content-Type": "application/json" },
}),
});
describe("AitbcClient", () => {
it("sends match requests", async () => {
const client = createClient();
const response = await client.match({ jobId: "job" });
expect(response.jobId).toBe("job");
expect(response.candidates).toEqual([]);
});
});