Skip to content

Commit 61fa2b2

Browse files
committed
test(docs): avoid URL default stringification
1 parent 9f7584c commit 61fa2b2

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

src/commands/docs.test.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,8 @@ describe("docsSearchCommand", () => {
5353

5454
expect(fetchMock).toHaveBeenCalledTimes(1);
5555
const [url, init] = fetchMock.mock.calls[0];
56-
expect(String(url)).toBe("https://docs.openclaw.ai/api/search?q=plugin+allowlist");
56+
expect(url).toBeInstanceOf(URL);
57+
expect(url.href).toBe("https://docs.openclaw.ai/api/search?q=plugin+allowlist");
5758
expect(init).toMatchObject({ headers: { Accept: "application/json" } });
5859
});
5960

0 commit comments

Comments
 (0)