fix: default complex junction crosswalks

This commit is contained in:
que01 committed 2026-09-11 12:40:46 +08:00
1 parent 3575e372bd
commit 376427d270
4 files changed
+7 -11

No files matched your search

+3 -6
View File
@@ -424,14 +424,11 @@ assert.equal(
assert.ok(complexGeometry.diagnostics.some((item) => item.rule === 'complex-junction-corner-facilities-omitted'));
assert.equal(
complexGeometry.crosswalks.features.some((feature) => feature.properties?.kind === 'complex-crosswalk'),
false,
'complex approaches without source crossing evidence must not synthesize zebra crossings',
true,
'complex approaches default to zebra crossings when pavement is available',
);
assert.ok(complexGeometry.diagnostics.some((item) => item.rule === 'complex-junction-crossing-source-missing'));
assert.match(
complexGeometry.diagnostics.find((item) => item.rule === 'complex-junction-generated').message,
/0 组斑马线/,
);
assert.match(complexGeometry.diagnostics.find((item) => item.rule === 'complex-junction-generated').message, /斑马线/);
const inferredStopLine = complexGeometry.vehicleStopLines.features.find(
(feature) => feature.properties?.kind === 'complex-stop-line',
);
+2 -2
View File
@@ -262,8 +262,8 @@ const unsourcedPreview = editPreview(unsourcedComplexArea, {
});
assert.equal(
unsourcedPreview.layers.crosswalks.features.some((feature) => feature.properties.kind === 'complex-crosswalk'),
false,
'the default fixture must not synthesize complex crossings without source evidence',
true,
'complex junctions default to crossings when pavement is available',
);
for (const response of [unsourcedState, unsourcedPreview])
assert.equal(