Improve map overlay ergonomics
This commit is contained in:
@@ -0,0 +1,32 @@
|
||||
from __future__ import annotations
|
||||
|
||||
from pathlib import Path
|
||||
|
||||
|
||||
ROOT = Path(__file__).resolve().parents[2]
|
||||
|
||||
|
||||
def test_map_workspace_exposes_layer_provenance_and_feature_summary() -> None:
|
||||
app = (ROOT / "frontend" / "src" / "App.tsx").read_text(encoding="utf-8")
|
||||
map_workspace = (ROOT / "frontend" / "src" / "components" / "map" / "MapWorkspace.tsx").read_text(
|
||||
encoding="utf-8"
|
||||
)
|
||||
css = (ROOT / "frontend" / "src" / "styles" / "app.css").read_text(encoding="utf-8")
|
||||
|
||||
assert "mapLayerSourceLabel" in app
|
||||
assert "mapLayerProvenance" in app
|
||||
assert "layer-provenance-rail" in map_workspace
|
||||
assert "feature-summary-grid" in map_workspace
|
||||
assert "feature-property-chip" in map_workspace
|
||||
assert ".layer-provenance-rail" in css
|
||||
assert ".feature-summary-grid" in css
|
||||
assert ".feature-property-chip" in css
|
||||
|
||||
|
||||
def test_map_workspace_has_clear_empty_result_layer_guidance() -> None:
|
||||
map_workspace = (ROOT / "frontend" / "src" / "components" / "map" / "MapWorkspace.tsx").read_text(
|
||||
encoding="utf-8"
|
||||
)
|
||||
|
||||
assert "No active vector or result layer" in map_workspace
|
||||
assert "Open a dataset, detection run, segmentation run or change result to draw it here." in map_workspace
|
||||
Reference in New Issue
Block a user