Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Godot 4 Yield To Fix #421

Merged
merged 1 commit into from
Sep 21, 2022
Merged

Conversation

Tim-Fronsee
Copy link
Contributor

@Tim-Fronsee Tim-Fronsee commented Sep 10, 2022

Summary

Fixes yielding (awaiting) for signals in Gut in Godot 4.

For testing, I used a simple GutTest which emits a button press (below);

func test_pressed():
	var button = autofree(SomeButton.new())
	add_child(button)
	await yield_to(button, "pressed", 1).timeout
        button.emit_signal("pressed")
	assert_signal_emitted(button, "pressed")

…ignals & assert_signal_emitted catches them in Godot 4
@bitwes bitwes merged commit 573650f into bitwes:godot_4 Sep 21, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants