test: assert sandbox mutation helper script

This commit is contained in:
Shakker
2026-05-08 10:47:31 +01:00
parent 52b7e8598b
commit 06d34c5e5f

View File

@@ -116,7 +116,9 @@ describe("sandbox fs bridge local backend e2e", () => {
await expect(
fs.readFile(path.join(workspaceDir, "nested", "hello.txt"), "utf8"),
).resolves.toBe("from-backend");
expect(scripts.some((script) => script.includes("operation = sys.argv[1]"))).toBe(true);
expect(scripts).toEqual(
expect.arrayContaining([expect.stringContaining("operation = sys.argv[1]")]),
);
} finally {
await fs.rm(stateDir, { recursive: true, force: true });
}