Fix normal radio report submission
Full build / Import + headless tests (push) Successful in 38s
Full build / Full desktop build + optional release (push) Failing after 4m22s

The radio button was connected only to the emergency hold handlers, so a
normal Send request never reached _submit. Connect pressed for non-emergency
calls while keeping hold-to-confirm exclusive to emergencies, and add tests
for click, short-hold rejection and full emergency hold. Headless 249/249,
Python 94/94.
This commit is contained in:
zwitschi committed 2026-11-01 21:37:39 +01:00
1 parent aa51ee331e
commit fac9b002c3
9 files changed
+62 -8

No files matched your search

+7
View File
@@ -105,6 +105,7 @@ func _init() -> void:
action_button.text = "Send request"
action_button.button_down.connect(func(): _start_hold())
action_button.button_up.connect(func(): _stop_hold(false))
action_button.pressed.connect(_on_action_pressed)
buttons.add_child(action_button)
var cancel_btn := Button.new()
cancel_btn.text = "Cancel"
@@ -144,6 +145,12 @@ func open(controller: Object, emergency: bool, truth: Dictionary) -> void:
_hold_time = 0.0
visible = true
## Non-emergency requests are a normal click. Emergency calls require the
## press-and-hold path, so the click release must not submit early.
func _on_action_pressed() -> void:
if not _emergency:
_submit()
func _start_hold() -> void:
_holding = _emergency
_hold_time = 0.0