GodotGitHub Actions Test AutomationContinuous IntegrationGame DevelopmentSoftware Testing 2 min read

GdUnit4 v7.0.0 Adds Headless Execution Support for Godot Engine

GdUnit4 v7.0.0 enables headless scene runner testing in Godot, eliminating the need for virtual displays on CI servers while noting limitations for visual…

GdUnit4 v7.0.0 for the Godot engine enables headless UI and scene runner test execution without an active display server. Previously, any test using the scene runner required a display even when simulating input events without checking rendered pixels, which forced CI servers to configure virtual displays because the command-line runner rejected headless execution without an explicit bypass flag.

Tracked as issue GD-1475, the update modifies how input reaches nodes by having the scene runner host the test scene inside its own viewport, routing simulated mouse, keyboard, and touch inputs directly to the scene hierarchy. Maintainers state the scene runner API stays identical, allowing you to run existing test suites headlessly without changing your code.

However, headless mode introduces rendering constraints because Godot suppresses visual rendering without a display server. Tests checking screenshots, viewport textures, shader output, or visibility notifiers fail without an active display server, meaning you should separate these visual checks into an isolated end-to-end test suite running on a display-enabled CI job.

Version 1.4.0 of the gdUnit4-action GitHub Action already supports this headless execution via a dedicated headless parameter. You can test the feature before the official v7.0.0 release by installing the current development version from the master branch.