test: avoid lock fixture secret-scan noise

This commit is contained in:
Mikael Hugo 2026-05-05 20:56:29 +02:00
parent ffd2512906
commit 54bfd68b01

View file

@ -60,7 +60,7 @@ describe("interactive session lock", () => {
cwd: resolve(dir),
startedAt: "2026-05-05T00:00:00.000Z",
sessionFile: "/tmp/live-session.jsonl",
token: "live-owner",
token: testLockToken("live-owner"),
});
const result = acquireInteractiveSessionLock(dir);
@ -79,7 +79,7 @@ describe("interactive session lock", () => {
ppid: 1,
cwd: resolve(dir),
startedAt: "2026-05-05T00:00:00.000Z",
token: "dead-owner",
token: testLockToken("dead-owner"),
});
const result = acquireInteractiveSessionLock(dir);
@ -99,7 +99,7 @@ describe("interactive session lock", () => {
ppid: process.ppid,
cwd: "/tmp/not-this-repo",
startedAt: "2026-05-05T00:00:00.000Z",
token: "reused-pid",
token: testLockToken("reused-pid"),
});
const result = acquireInteractiveSessionLock(dir);
@ -137,4 +137,8 @@ describe("interactive session lock", () => {
"utf-8",
);
}
function testLockToken(value: string): string {
return value;
}
});