Massive refactor (#165)

This commit is contained in:
Oliver King
2022-02-02 09:07:53 -05:00
committed by GitHub
parent 5cbd4acaca
commit ca8d2604ac
139 changed files with 19176 additions and 17005 deletions
+15
View File
@@ -0,0 +1,15 @@
import * as io from "@actions/io";
import { checkDockerPath } from "./dockerUtils";
describe("docker utilities", () => {
it("checks if docker is installed", async () => {
// docker installed
const path = "path";
jest.spyOn(io, "which").mockImplementationOnce(async () => path);
expect(() => checkDockerPath()).not.toThrow();
// docker not installed
jest.spyOn(io, "which").mockImplementationOnce(async () => undefined);
await expect(() => checkDockerPath()).rejects.toThrow();
});
});