You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2026-01-05 19:31:35 +00:00
Add Android instrumented tests to the app module
This builds on the work from @dsnopek in https://github.com/dsnopek/javaclasswrapper-test, by importing the set of JavaClassWrapper tests from that repo within the Godot core repo in order to bootstrap and standardize how we write and run Android instrumented tests. The approach used here should serve as a base to build upon to expand the set of instrumented tests used to validate the project's stability. Co-authored-by: David Snopek <dsnopek@gmail.com>
This commit is contained in:
@@ -83,4 +83,13 @@ public class GodotApp extends GodotActivity {
|
||||
super.onGodotMainLoopStarted();
|
||||
runOnUiThread(updateWindowAppearance);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onGodotForceQuit(Godot instance) {
|
||||
if (!BuildConfig.FLAVOR.equals("instrumented")) {
|
||||
// For instrumented builds, we disable force-quitting to allow the instrumented tests to complete
|
||||
// successfully, otherwise they fail when the process crashes.
|
||||
super.onGodotForceQuit(instance);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user