Fix to Fix error in previous fix, and adapt tests

This commit is contained in:
Antoni Ros Zafont 2026-01-16 20:42:10 +01:00
parent 22cdf40d6e
commit e6f8bea804
2 changed files with 5 additions and 4 deletions

View file

@ -63,7 +63,7 @@ test("invokes soffice with --headless and outdir derived from targetPath", async
expect(cmd).toBe("soffice");
expect(args).toEqual([
"--headless",
`--infilter="MS Word 2007 XML"`,
`--infilter=MS Word 2007 XML`,
"--convert-to",
"odt:writer8",
"--outdir",
@ -77,8 +77,7 @@ test("uses only outFilter when input has no filter (e.g., pdf -> txt)", async ()
const { args } = requireDefined(calls[0], "Expected at least one execFile call");
expect(args).not.toContainEqual(expect.stringMatching(/^--infilter=/));
expect(args).toEqual(["--headless", "--convert-to", "txt", "--outdir", "out", "in.pdf"]);
expect(args).toEqual(["--headless", "--infilter=writer_pdf_import","--convert-to", "txt:Text", "--outdir", "out", "in.pdf"]);
});
test("uses only infilter when convertTo has no out filter (e.g., docx -> pdf)", async () => {