Skip to content

Commit 7f7dd67

Browse files
committed
chore: formatting
1 parent d3658a6 commit 7f7dd67

File tree

2 files changed

+8
-9
lines changed

2 files changed

+8
-9
lines changed

lib/extractor/index.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -248,11 +248,11 @@ function layersWithLatestFileModifications(
248248
return extractedLayers;
249249
}
250250

251-
/**
252-
* check if a file is 'whited out', which is shown by
253-
* prefixing the filename with a .wh.
254-
* https://www.madebymikal.com/interpreting-whiteout-files-in-docker-image-layers/
255-
*/
251+
/**
252+
* check if a file is 'whited out', which is shown by
253+
* prefixing the filename with a .wh.
254+
* https://www.madebymikal.com/interpreting-whiteout-files-in-docker-image-layers/
255+
*/
256256
export function isWhitedOutFile(filename: string) {
257257
return filename.includes(".wh.");
258258
}

test/lib/extractor/index.spec.ts

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
1-
import { getContentAsString } from "../../../lib/extractor";
1+
import { getContentAsString, isWhitedOutFile } from "../../../lib/extractor";
22
import { ExtractAction, ExtractedLayers } from "../../../lib/extractor/types";
3-
import { isWhitedOutFile } from "../../../lib/extractor";
43

54
describe("index", () => {
65
test("getContentAsString() does matches when a pattern is used in the extract action", async () => {
@@ -38,11 +37,11 @@ describe("isWhitedOutFile", () => {
3837
expect(isWhitedOutFile("/etc/wh.hosts")).toBe(false);
3938
expect(isWhitedOutFile("/etc/.whosts")).toBe(false);
4039
expect(isWhitedOutFile("/etc/whhosts")).toBe(false);
41-
40+
4241
// dots in wrong places
4342
expect(isWhitedOutFile("/etc/.w.h.hosts")).toBe(false);
4443
expect(isWhitedOutFile("/etc/..wh..hosts")).toBe(false);
45-
44+
4645
// case sensitive
4746
expect(isWhitedOutFile("/etc/.WH.hosts")).toBe(false);
4847
expect(isWhitedOutFile("/etc/.Wh.hosts")).toBe(false);

0 commit comments

Comments
 (0)