@catladder/pipeline
Version:
Panter workflow for cloud CI/CD and DevOps
34 lines (31 loc) • 738 B
text/typescript
import { mkdir, rm, writeFile } from "fs/promises";
import { createYamlLocalPipeline } from "./__utils__/helpers";
import config from "./rails-k8s-with-worker";
import { merge } from "lodash";
import { join } from "path";
it("matches snapshot with a Dockerfile", async () => {
const appDir = ".temp-with-dockerfile";
try {
await rm(appDir, {
recursive: true,
});
} catch (e) {
// ignore
}
await mkdir(appDir);
await writeFile(join(appDir, "Dockerfile"), "");
expect(
await createYamlLocalPipeline(
merge(config, {
components: {
app: {
dir: appDir,
},
},
}),
),
).toMatchSnapshot();
await rm(appDir, {
recursive: true,
});
});