1
0
mirror of https://github.com/godotengine/godot.git synced 2025-11-29 16:16:38 +00:00

Fix various errors when running the unit tests

Co-authored-by: bruvzg <7645683+bruvzg@users.noreply.github.com>
This commit is contained in:
RedworkDE
2023-05-09 15:50:48 +02:00
parent 668cf3c66f
commit 8e7afec479
9 changed files with 22 additions and 21 deletions

View File

@@ -581,8 +581,6 @@ void Main::test_cleanup() {
TextServerManager::get_singleton()->get_interface(i)->cleanup();
}
EngineDebugger::deinitialize();
ResourceLoader::remove_custom_loaders();
ResourceSaver::remove_custom_savers();
@@ -594,6 +592,7 @@ void Main::test_cleanup() {
GDExtensionManager::get_singleton()->deinitialize_extensions(GDExtension::INITIALIZATION_LEVEL_SCENE);
uninitialize_modules(MODULE_INITIALIZATION_LEVEL_SCENE);
unregister_platform_apis();
unregister_driver_types();
unregister_scene_types();
@@ -604,8 +603,12 @@ void Main::test_cleanup() {
uninitialize_modules(MODULE_INITIALIZATION_LEVEL_SERVERS);
unregister_server_types();
EngineDebugger::deinitialize();
OS::get_singleton()->finalize();
if (packed_data) {
memdelete(packed_data);
}
if (translation_server) {
memdelete(translation_server);
}
@@ -621,16 +624,13 @@ void Main::test_cleanup() {
if (globals) {
memdelete(globals);
}
if (packed_data) {
memdelete(packed_data);
}
if (engine) {
memdelete(engine);
}
unregister_core_driver_types();
uninitialize_modules(MODULE_INITIALIZATION_LEVEL_CORE);
unregister_core_extensions();
uninitialize_modules(MODULE_INITIALIZATION_LEVEL_CORE);
unregister_core_types();
OS::get_singleton()->finalize_core();