Files
test-repo/tests/integration/__tests__/mockable.js
T

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

12 lines
356 B
JavaScript
Raw Normal View History

2025-04-23 23:42:19 +08:00
import url from "node:url";
import { prettierCliMockableEntry } from "../env.js";
2020-05-08 21:41:46 +08:00
2025-04-23 23:42:19 +08:00
async function getCliMockable() {
const cli = await import(url.pathToFileURL(prettierCliMockableEntry));
return cli.mockable;
}
2020-05-08 21:41:46 +08:00
2025-04-23 23:42:19 +08:00
test("isCI", async () => {
const mockable = await getCliMockable();
expect(typeof mockable.implementations.isCI()).toBe("boolean");
2020-08-21 09:43:24 +08:00
});