feat(junction): validate entry ring geometry

This commit is contained in:
que01 committed 2026-09-09 14:09:44 +08:00
1 parent a90826efed
commit a37c707188
3 files changed
+32 -1

No files matched your search

@@ -559,3 +559,17 @@ assert.deepEqual(
],
'BoundaryGraph must expose the canonical entry ring consumed by compilation',
);
assert.ok(teeBoundaryGraph.sections.every((section) => section.ringStatus === 'supported'));
const zeroWidth = topology('zero-width-entry', [
{ widthMeters: 0, line: [point(0, 0), point(0, 40)] },
{ widthMeters: 5, line: [point(0, 0), point(40, 0)] },
{ widthMeters: 5, line: [point(0, 0), point(-40, 0)] },
]);
const zeroWidthGraph = buildJunctionBoundaryGraph(
zeroWidth.topology,
point(0, 0),
{ outerRadiusFor: () => 24, innerRadiusFor: () => 10 },
zeroWidth.helpers,
);
assert.equal(zeroWidthGraph.sections[0].ringStatus, 'invalid');