test(make-pdf): clean up the pdftotext shim tmpdir after the suite

Wave polish on the #2690 absorption: the describe-scope mkdtemp left one
directory per run.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
Garry Tan
2026-08-31 20:57:08 +00:00
co-authored by Claude Fable 5
parent 5b55be1f7e
commit e6e479e73f
+2 -1
View File
@@ -6,7 +6,7 @@
* mocked by manipulating strings directly).
*/
import { describe, expect, test } from "bun:test";
import { afterAll, describe, expect, test } from "bun:test";
import * as fs from "node:fs";
import * as os from "node:os";
@@ -226,6 +226,7 @@ describe("resolvePdftotext (override resolution, v1.24-aligned)", () => {
describe("describeBinary (version + flavor probe)", () => {
const shimDir = fs.mkdtempSync(path.join(os.tmpdir(), "pdftotext-shim-"));
afterAll(() => fs.rmSync(shimDir, { recursive: true, force: true }));
function shim(name: string, body: string): string {
if (process.platform === "win32") return "";