diff --git a/src/game/engine/tests/integration/test_gd_turn_processor.gd b/src/game/engine/tests/integration/test_gd_turn_processor.gd index 691138bc..de05d6b5 100644 --- a/src/game/engine/tests/integration/test_gd_turn_processor.gd +++ b/src/game/engine/tests/integration/test_gd_turn_processor.gd @@ -175,6 +175,12 @@ func _make_state() -> RefCounted: var state: RefCounted = ClassDB.instantiate("GdGameState") as RefCounted assert_not_null(state, "GdGameState must be registered") state.call("create_grid", MAP_SIZE, MAP_SIZE) + # p2-71c — add_player_militarist refuses to spawn (returns -1) unless the + # runtime units catalog is loaded first (otherwise MapUnit base_moves=0 and + # the AI freezes past turn 0). Harvest the same catalog the real bridge does. + var units_json: String = AiTurnBridge._harvest_runtime_units_json() + assert_false(units_json.is_empty(), "runtime units catalog must harvest from resources/units") + state.call("set_units_runtime_catalog_json", units_json) return state