chore(plugins): sync the captured final review base
This commit is contained in:
@@ -257,9 +257,11 @@ it.skipIf(process.platform === "win32").each(["cancelled", "timeout"] as const)(
|
||||
failures: [expect.objectContaining({ reason: "run-token-mismatch" })],
|
||||
});
|
||||
expect(failure.cleanupResult).toEqual(cleanup);
|
||||
expect(failure.resources).toEqual(
|
||||
expect.arrayContaining([request.runId]),
|
||||
);
|
||||
expect(failure.resources).toEqual([
|
||||
request.runId,
|
||||
`pid:${launched.ownership.leaderPid}`,
|
||||
`process-group:${launched.ownership.processGroupId}`,
|
||||
]);
|
||||
// An unresolved member does not grant authority to signal the shared group.
|
||||
const acquiredPid = launched.ownership.leaderPid;
|
||||
expect(() => process.kill(acquiredPid, 0)).not.toThrow();
|
||||
|
||||
@@ -196,9 +196,9 @@ itWithCaptureCapability(
|
||||
result.value.frames.map(({ at_ms }) => at_ms),
|
||||
"capture-relative frame times stay ordered and nonnegative",
|
||||
).toEqual(
|
||||
[...result.value.frames.map(({ at_ms }) => at_ms)].sort(
|
||||
(left, right) => left - right,
|
||||
),
|
||||
result.value.frames
|
||||
.map(({ at_ms }) => at_ms)
|
||||
.sort((left, right) => left - right),
|
||||
);
|
||||
expect(result.value.frames.every(({ at_ms }) => at_ms >= 0)).toBe(true);
|
||||
expect(result.value.exit.reason).toBe("exited");
|
||||
|
||||
@@ -28,6 +28,35 @@ const identitySchema = z.object({
|
||||
const itWithLinuxCaptureCapability =
|
||||
process.platform === "linux" ? itWithCaptureCapability : it.skip;
|
||||
|
||||
itWithCaptureCapability(
|
||||
"captures a POSIX PATH executable with a literal backslash in its basename",
|
||||
async () => {
|
||||
const root = await createTestTempDirectory("rea-process-backslash-name-");
|
||||
const bin = join(root, "bin");
|
||||
await mkdir(bin);
|
||||
const command = "selected\\node";
|
||||
const selected = join(bin, command);
|
||||
await symlink(process.execPath, selected);
|
||||
const scenario = parseProcessScenario({
|
||||
executable: command,
|
||||
working_directory: root,
|
||||
environment: { PATH: bin },
|
||||
arguments: ["-e", 'process.stdout.write("selected executable")'],
|
||||
settle_ms: 100,
|
||||
});
|
||||
const result = await captureProcessScenario(scenario);
|
||||
if (!result.ok) throw result.error;
|
||||
expect(result.value.frames.map(({ data }) => data).join("")).toBe(
|
||||
"selected executable",
|
||||
);
|
||||
expect(result.value.exit).toMatchObject({ code: 0, reason: "exited" });
|
||||
expect(result.value.cleanup).toMatchObject({
|
||||
owned_process_group: "verified",
|
||||
temporary_root: "removed",
|
||||
});
|
||||
},
|
||||
);
|
||||
|
||||
itWithCaptureCapability(
|
||||
"preserves numeric reports and original normalized PTY text in Evidence",
|
||||
async () => {
|
||||
|
||||
Reference in New Issue
Block a user