diff --git a/test/junction-build-plan-counterexamples.js b/test/junction-build-plan-counterexamples.js index f5930a2..1730d5a 100644 --- a/test/junction-build-plan-counterexamples.js +++ b/test/junction-build-plan-counterexamples.js @@ -150,6 +150,16 @@ const teeCore = buildCoreClosure(tee.topology, teeBoundaryGraph, point(0, 0)); assert.equal(teeCore.status, 'supported'); assert.equal(teeCore.sharedEdgeRefs.length, teeBoundaryGraph.sections.length); assert.ok(teeCore.ring.every((coordinate) => coordinate.every(Number.isFinite))); +const safeHole = buildJunctionBoundaryGraph( + tee.topology, + point(0, 0), + { outerRadiusFor: () => 30, innerRadiusFor: () => 10 }, + tee.helpers, + [{ id: 'island:hole', isHole: true, ring: [point(-2, -2), point(2, -2), point(2, 2), point(-2, 2), point(-2, -2)] }], +); +const holedCore = buildCoreClosure(tee.topology, safeHole, point(0, 0)); +assert.equal(holedCore.status, 'supported'); +assert.equal(holedCore.holes.length, 1); const exclusionRing = [point(-1, -1), point(1, -1), point(1, 1), point(-1, 1), point(-1, -1)]; const teeWithIsland = buildJunctionBoundaryGraph( tee.topology,