test(junction): protect touching exclusion boundaries

This commit is contained in:
que01 committed 2026-09-09 13:50:54 +08:00
1 parent d35b704e5e
commit f4cf42f1c6
1 file changed
+13
@@ -534,3 +534,16 @@ const irregularSixArmGraph = buildJunctionBoundaryGraph(
irregularSixArm.helpers,
);
assertCoreGeometry(irregularSixArm.topology, irregularSixArmGraph, point(0, 0));
const touchingExclusion = [point(-3, 10), point(3, 10), point(3, 16), point(-3, 16), point(-3, 10)];
const touchingGraph = buildJunctionBoundaryGraph(
tee.topology,
point(0, 0),
{ outerRadiusFor: () => 30, innerRadiusFor: () => 10 },
tee.helpers,
[{ id: 'island:touching', ring: touchingExclusion }],
);
assert.ok(
touchingGraph.sections.some((section) => section.exclusionStatus === 'overlaps-known-region'),
'a boundary-touching exclusion must remain protected',
);