fix: harden structured configuration comparisons (#467)

* refactor(process): split ownership observation helpers

* fix: compare structured configuration canonically

* test(conformance): tolerate Markdown line wrapping

* refactor: name caught values explicitly
This commit is contained in:
morluto
2026-08-09 11:58:01 +08:00
committed by GitHub
parent 8f229ede70
commit 6901edc05d
15 changed files with 319 additions and 199 deletions
@@ -139,6 +139,26 @@ it("classifies missing observations as unknown and one-sided evidence as added",
expect(unknown.status).toBe("unknown");
});
it("treats equivalent normalization records as equal regardless of member order", () => {
const capture = emptyCapture();
expect(
compareProcessCaptures(capture, {
...capture,
normalization: {
patterns: [],
time_bucket_ms: 10,
ports: true,
pids: true,
paths: true,
},
}),
).toMatchObject({
status: "unchanged",
first_divergence: { status: "none" },
});
});
it("compares raw terminal chunks even when rendered states agree", () => {
const capture = {
schema_version: 4 as const,