feat: add legend to EM path overview
This commit is contained in:
@@ -73,6 +73,18 @@ internal static class WebAssetChecks
|
||||
Verification.True(js.Contains("未收到 Local G2 路径"), "empty overview names the missing source");
|
||||
Verification.True(html.Contains("occupancy-grid"), "single occupancy canvas exists");
|
||||
Verification.True(html.Contains("world-overlay"), "SVG trajectory overlay exists");
|
||||
Verification.True(html.Contains("id=\"world-legend\""),
|
||||
"overview contains a screen-space legend host");
|
||||
Verification.True(html.Contains("aria-label=\"路径图例\""),
|
||||
"overview legend has a Chinese accessible name");
|
||||
Verification.True(css.Contains(".world-legend"),
|
||||
"overview legend has a screen-space visual container");
|
||||
Verification.True(css.Contains(".world-legend-swatch"),
|
||||
"overview legend exposes semantic line and marker samples");
|
||||
Verification.True(js.Contains("function renderWorldLegend("),
|
||||
"overview builds legend entries from current snapshot data");
|
||||
Verification.True(js.Contains("legendChinese"),
|
||||
"overview reuses exported Chinese polyline legends");
|
||||
Verification.True(js.Contains("atob"), "compact occupancy bitset is decoded in browser");
|
||||
Verification.True(!html.Contains("http://") && !html.Contains("https://"), "page has no CDN URL");
|
||||
}
|
||||
@@ -82,6 +94,12 @@ internal static class WebAssetChecks
|
||||
PlanningVisualizationStaticSnapshot staticSnapshot = SampleSnapshotFactory.CreateStaticSnapshot();
|
||||
PlanningVisualizationDynamicSnapshot dynamicSnapshot = SampleSnapshotFactory.CreateDynamicSnapshot(1L);
|
||||
|
||||
Verification.True(staticSnapshot.StaticPolylines.Any(line => line.Kind == "coarse"),
|
||||
"smoke snapshot exposes the coarse comparison path");
|
||||
Verification.True(staticSnapshot.StaticPolylines.Any(line => line.Kind == "local-g2"),
|
||||
"smoke snapshot exposes the smoothed comparison path");
|
||||
Verification.True(staticSnapshot.StaticMarkers.Any(marker => marker.Kind == "smooth-start"),
|
||||
"smoke snapshot exposes the smoothed-path start marker");
|
||||
Verification.Equal(2, staticSnapshot.DirectionSegments.Count, "smoke snapshot has two direction segments");
|
||||
Verification.True(staticSnapshot.StaticMarkers.Any(marker => marker.Kind == "gear-switch"), "smoke snapshot has a gear marker");
|
||||
Verification.True(staticSnapshot.ConfigurationGroups.Count > 0, "smoke snapshot has effective configuration");
|
||||
|
||||
Reference in New Issue
Block a user