fix(ci): restore capture and maintenance regression checks
This commit is contained in:
@@ -275,7 +275,10 @@ itWithCaptureCapability(
|
||||
const projected = projectAnalysisError(result.error);
|
||||
expect(projected).toMatchObject({
|
||||
code: "cleanup_incomplete",
|
||||
details: { cleanup: "incomplete", resources: ["owned_process_group"] },
|
||||
details: {
|
||||
cleanup: "incomplete",
|
||||
resources: ["owned_process_group", "temporary_root"],
|
||||
},
|
||||
});
|
||||
expect(projected).not.toHaveProperty("stack");
|
||||
expect(projected).not.toHaveProperty("cause");
|
||||
|
||||
@@ -169,9 +169,14 @@ itWithCaptureCapability.each(["cli", "mcp"] as const)(
|
||||
await writeFile(join(root, "z.txt"), "unchanged");
|
||||
const scenario = {
|
||||
executable: process.execPath,
|
||||
arguments: ["-e", "require('node:fs').writeFileSync('a.txt','added')"],
|
||||
arguments: [
|
||||
"-e",
|
||||
"const fs=require('node:fs');fs.mkdirSync('added');fs.writeFileSync('added/a.txt','added')",
|
||||
],
|
||||
working_directory: root,
|
||||
filesystem_observation_paths: [root],
|
||||
// Before capture the first root is absent. After capture it consumes
|
||||
// both entries, so the unchanged second root is certainly unexamined.
|
||||
filesystem_observation_paths: [join(root, "added"), join(root, "z.txt")],
|
||||
limits: { files: 2 },
|
||||
};
|
||||
const evidence = await (adapter === "cli" ? captureViaCli : captureViaMcp)(
|
||||
@@ -181,13 +186,13 @@ itWithCaptureCapability.each(["cli", "mcp"] as const)(
|
||||
expect(capture.truncated).toBe(true);
|
||||
expect(await readFile(join(root, "z.txt"), "utf8")).toBe("unchanged");
|
||||
expect(
|
||||
capture.filesystem_effects.find(({ path }) => path === "root_0:z.txt")
|
||||
capture.filesystem_effects.find(({ path }) => path === "root_1:.")
|
||||
?.status,
|
||||
).toBe("unknown");
|
||||
expect(
|
||||
capture.filesystem_checkpoints
|
||||
.find(({ name }) => name === "after_settlement")
|
||||
?.effects.find(({ path }) => path === "root_0:z.txt")?.status,
|
||||
?.effects.find(({ path }) => path === "root_1:.")?.status,
|
||||
).toBe("unknown");
|
||||
},
|
||||
20_000,
|
||||
|
||||
@@ -195,8 +195,12 @@ itWithCaptureCapability.each(["cli", "mcp"] as const)(
|
||||
"files_limit",
|
||||
);
|
||||
expect(
|
||||
result.files_after.find(({ path }) => path === "root_0:b.txt")?.sha256,
|
||||
result.files_before.find(({ path }) => path === "root_0:b.txt")?.sha256,
|
||||
).toBeNull();
|
||||
const after = result.files_after.find(
|
||||
({ path }) => path === "root_0:b.txt",
|
||||
);
|
||||
if (after !== undefined) expect(after.sha256).toBeNull();
|
||||
expect(processSourceTruncated(result, "terminal_rendered")).toBe(true);
|
||||
expect(compareProcessCaptures(result, result)).toMatchObject({
|
||||
terminal: "unknown",
|
||||
|
||||
Reference in New Issue
Block a user