Skip to content

abso-core

Public

abso is version control for agents: the client, the engine and a server you can run on your own Cloudflare account.

Check passed

Versions 117 to 118

Compare

+14 −0 in 1 place
Lines 8–27 at 118 (were 8–13 at 117)
88import { lines, Repo } from "./helpers.ts";
99
1010describe("View", () => {
11+ it("current indexed paths do not retain deleted historical file layouts", () => {
12+ const retained = (count: number) => {
13+ const files: Record<string, string> = { "live.txt": "live\n" };
14+ for (let i = 0; i < count; i++) files[`old-${i}.txt`] = "gone\n";
15+ const repo = Repo.init(files);
16+ repo.edit({ edits: Array.from({ length: count }, (_, i) => ({ file: `old-${i}.txt`, old: "gone\n", new: "" })) });
17+ const view = new View(repo.graph, new StableOverlaySet<AtomId>(["a0", "a1"]));
18+ assert.deepEqual(view.files(), { "live.txt": "live\n" });
19+ const weight = view.weight();
20+ assert.equal(view.knownPaths().length, count + 1, "explicit historical enumeration is preserved");
21+ return weight;
22+ };
23+ assert.equal(retained(200), retained(20), "deleted path count must not grow current-view retained state");
24+ });
1125 it("reuses indexed membership across a long run of lines without a history-sized memo", () => {
1226 const repo = Repo.init({ "long.txt": "line\n".repeat(1000) });
1327 class CountingSet extends StableOverlaySet<AtomId> {
MCP
compare on this site's /mcp
CLI
abso diff 117 118 src/engine/test/view.test.ts --json
JSON
/christopher/abso-core/compare/117..118?file=src%2Fengine%2Ftest%2Fview.test.ts&format=json