Skip to content

Commit d315f7e

Browse files
authored
Merge pull request #4 from tychenjiajun/fix/remove-windows-flag
Fix/remove windows flag
2 parents e2e4cf4 + 6a8839b commit d315f7e

File tree

3 files changed

+13
-7
lines changed

3 files changed

+13
-7
lines changed

src/__tests__/raw-therapee-wrap-windows.test.ts

Lines changed: 12 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -61,10 +61,17 @@ describe("Windows platform tests", () => {
6161

6262
await convertDngToImage(parameters);
6363

64-
// Check that the arguments include the Windows flag
65-
expect(spawn).toHaveBeenCalledWith(
66-
"rawtherapee-cli",
67-
expect.arrayContaining(["-w"]),
68-
);
64+
// Check that the arguments no longer include the Windows flag
65+
const expectedArgs = [
66+
"-Y",
67+
"-O",
68+
path.join(TEST_OUTPUT_DIR, "output.jpg"),
69+
"-j90",
70+
"-js3",
71+
"-b16",
72+
"-c",
73+
TEST_INPUT_FILE,
74+
];
75+
expect(spawn).toHaveBeenCalledWith("rawtherapee-cli", expectedArgs);
6976
});
7077
});

src/__tests__/raw-therapee-wrap.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ it("convertDngToImage should throw error when output directory does not exist",
9797
};
9898

9999
await expect(convertDngToImage(parameters)).rejects.toThrow(
100-
/Output directory does not exist/,
100+
/Failed to create output directory/,
101101
);
102102
});
103103

src/raw-therapee-wrap.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,6 @@ function buildCliArguments({
153153
input: string;
154154
}) {
155155
const cliArguments = [
156-
...(os.platform() === "win32" ? ["-w"] : []),
157156
"-Y",
158157
pp3Path ? "-o" : "-O",
159158
output,

0 commit comments

Comments
 (0)