From f4cf42f1c68c969cd198d730b109f75df4d87a8e Mon Sep 17 00:00:00 2001 From: que01 Date: Wed, 9 Sep 2026 13:50:54 +0800 Subject: [PATCH] test(junction): protect touching exclusion boundaries --- test/junction-build-plan-counterexamples.js | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/test/junction-build-plan-counterexamples.js b/test/junction-build-plan-counterexamples.js index 84cd56b..3b392da 100644 --- a/test/junction-build-plan-counterexamples.js +++ b/test/junction-build-plan-counterexamples.js @@ -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', +);