fix(ui): PR #131 review round 1 — retire starchart, harden registry
Addresses blocker comments from PR review: - Delete star_map.gd and star_map.tscn — dead implant/map/starchart HudGroups registration that should have landed with the atlas unification (D-191 criterion 1) - Remove test_star_map_is_accessible_from_insert_ui and test_star_map_scene_exists from test_sprint30.gd — D-191 supersedes the insert-UI accessibility pattern - ImplantRegistry._scan() now detects default_key collisions (first-wins with push_warning) and validates default_mode against HudGroups.Mode enum (skip + warn on invalid) star_map_data.json remains — still used by atlas_app and economics_app for system index lookups. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -550,41 +550,3 @@ func test_overhead_anchor_offset_constant() -> void:
|
||||
assert_bool(attachment == null).override_failure_message(
|
||||
"_overhead_attachment must be null before skeleton is loaded"
|
||||
).is_true()
|
||||
|
||||
|
||||
# =============================================================================
|
||||
# #674 — Star map insert module (test-first)
|
||||
# =============================================================================
|
||||
|
||||
func test_star_map_scene_exists() -> void:
|
||||
## [ACCEPTANCE #674] The star map scene must exist at the expected path.
|
||||
## WILL FAIL until #674 is implemented.
|
||||
var expected_path := "res://ui/star_map.tscn"
|
||||
assert_bool(ResourceLoader.exists(expected_path)).override_failure_message(
|
||||
"[#674] Star map scene must exist at res://ui/star_map.tscn"
|
||||
).is_true()
|
||||
|
||||
|
||||
func test_star_map_is_accessible_from_insert_ui() -> void:
|
||||
## [ACCEPTANCE #674] The star map module must be reachable from the insert UI.
|
||||
## Verify via HUD or main scene that a star_map node/scene is connected.
|
||||
## WILL FAIL until #674 wires the scene into the insert layer.
|
||||
var hud_scene_path := "res://ui/hud.tscn"
|
||||
if not ResourceLoader.exists(hud_scene_path):
|
||||
push_warning("test_star_map_is_accessible_from_insert_ui: HUD scene not found — skipping")
|
||||
return
|
||||
var packed := load(hud_scene_path) as PackedScene
|
||||
if packed == null:
|
||||
return
|
||||
var hud := packed.instantiate()
|
||||
if hud == null:
|
||||
return
|
||||
auto_free(hud)
|
||||
add_child(hud)
|
||||
await get_tree().process_frame
|
||||
|
||||
# Star map must be reachable as a named node from the HUD or insert layer
|
||||
var star_map := hud.get_node_or_null("StarMap")
|
||||
assert_bool(star_map != null).override_failure_message(
|
||||
"[#674] HUD must contain a StarMap node accessible from the insert UI"
|
||||
).is_true()
|
||||
|
||||
Reference in New Issue
Block a user