From be7878a1993d501a6a8551877941a5c77d1b30b0 Mon Sep 17 00:00:00 2001 From: VinPropane Date: Wed, 17 Jun 2026 21:11:27 -0400 Subject: [PATCH] NEO-142: fix GdUnit HTTPClient method enum in faction tests Use METHOD_GET default params matching existing client test mocks; auto_free progress client stub to avoid orphan exit code. --- client/test/faction_standing_client_test.gd | 4 ++-- client/test/faction_standing_hud_test.gd | 6 ++++-- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/client/test/faction_standing_client_test.gd b/client/test/faction_standing_client_test.gd index 4540ea2..a2fe6c2 100644 --- a/client/test/faction_standing_client_test.gd +++ b/client/test/faction_standing_client_test.gd @@ -23,7 +23,7 @@ class MockHttpTransport: func request( url: String, _custom_headers: PackedStringArray = PackedStringArray(), - _method: HTTPClient.Method = HTTPClient.Method.GET, + _method: HTTPClient.Method = HTTPClient.METHOD_GET, _request_data: String = "" ) -> Error: last_url = url @@ -48,7 +48,7 @@ class PendingSyncHttpTransport: func request( _url: String, _custom_headers: PackedStringArray = PackedStringArray(), - _method: HTTPClient.Method = HTTPClient.Method.GET, + _method: HTTPClient.Method = HTTPClient.METHOD_GET, _request_data: String = "" ) -> Error: request_count += 1 diff --git a/client/test/faction_standing_hud_test.gd b/client/test/faction_standing_hud_test.gd index c39b1b9..5af365d 100644 --- a/client/test/faction_standing_hud_test.gd +++ b/client/test/faction_standing_hud_test.gd @@ -19,7 +19,7 @@ class MockHttpTransport: func request( _url: String, _custom_headers: PackedStringArray = PackedStringArray(), - _method: HTTPClient.Method = HTTPClient.Method.GET, + _method: HTTPClient.Method = HTTPClient.METHOD_GET, _request_data: String = "" ) -> Error: request_completed.emit( @@ -147,12 +147,14 @@ func test_accept_result_received_paints_readable_faction_gate_blocked() -> void: defs_client.call("request_sync_from_server") var controller: Node = QuestHudController.new() var accept_label := Label.new() + var progress_client := Node.new() auto_free(controller) auto_free(accept_label) + auto_free(progress_client) add_child(controller) controller.set("_defs_client", defs_client) controller.set("_accept_label", accept_label) - controller.set("_progress_client", Node.new()) + controller.set("_progress_client", progress_client) controller.call( "_on_faction_standing_received", {"schemaVersion": 1, "playerId": "dev-local-1", "factions": []} )