test: define final character HUD contracts

This commit is contained in:
goose
2026-10-09 12:21:45 -04:00
parent 78f4744c3f
commit c410f830e3
7 changed files with 193 additions and 91 deletions
+10
View File
@@ -30,6 +30,16 @@ func test_f_starts_ranged_targeting_and_ctrl_s_or_v_requests_a_manual_save() ->
assert_eq(router.action_from_input(_action_event(&"ranged")).kind, &"ranged")
assert_eq(router.action_from_input(_action_event(&"save")).kind, &"save")
func test_character_opens_with_physical_c_while_p_is_free_and_southeast_uses_keypad_3() -> void:
var character_c := _key_event(KEY_C)
var legacy_character_p := _key_event(KEY_P)
var southeast_keypad_3 := _key_event(KEY_KP_3)
assert_true(InputMap.action_has_event(&"character", character_c), "C is the physical character-sheet binding")
assert_false(InputMap.action_has_event(&"character", legacy_character_p), "P must no longer open the character sheet")
assert_true(InputMap.action_has_event(&"move_southeast", southeast_keypad_3), "South-east is bound to keypad 3")
assert_false(InputMap.action_has_event(&"move_southeast", character_c), "C must no longer move south-east")
func test_action_from_input_maps_the_complete_command_vocabulary() -> void:
var router := ActionRouter.new(null)
var expected := {