Compare commits

...

1 Commits

Author SHA1 Message Date
thucpn b3b7fc5551 test: crypto compatity with node18 2025-03-19 07:42:58 +07:00
+14
View File
@@ -28,4 +28,18 @@ describe("Image Generator Tool", () => {
expect(result.imageUrl).toBeDefined();
expect(result.errorMessage).toBeUndefined();
});
test("does not throw error on valid prompt", async () => {
const imgTool = imageGenerator({
apiKey: process.env.STABILITY_API_KEY!,
outputDir: "output",
fileServerURLPrefix: "http://localhost:3000",
});
expect(async () => {
await imgTool.call({
prompt: "a scenic mountain landscape",
});
}).not.toThrow();
});
});