diff options
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/test_basis.h | 2 | ||||
| -rw-r--r-- | tests/test_class_db.h | 20 | ||||
| -rw-r--r-- | tests/test_color.h | 5 | ||||
| -rw-r--r-- | tests/test_command_queue.h | 4 | ||||
| -rw-r--r-- | tests/test_expression.h | 6 | ||||
| -rw-r--r-- | tests/test_gradient.h | 4 | ||||
| -rw-r--r-- | tests/test_gui.cpp | 2 | ||||
| -rw-r--r-- | tests/test_list.h | 2 | ||||
| -rw-r--r-- | tests/test_macros.h | 4 | ||||
| -rw-r--r-- | tests/test_main.cpp | 2 | ||||
| -rw-r--r-- | tests/test_math.cpp | 10 | ||||
| -rw-r--r-- | tests/test_method_bind.h | 2 | ||||
| -rw-r--r-- | tests/test_oa_hash_map.cpp | 2 | ||||
| -rw-r--r-- | tests/test_ordered_hash_map.h | 6 | ||||
| -rw-r--r-- | tests/test_physics_2d.cpp | 4 | ||||
| -rw-r--r-- | tests/test_physics_3d.cpp | 4 | ||||
| -rw-r--r-- | tests/test_render.cpp | 2 | ||||
| -rw-r--r-- | tests/test_shader_lang.cpp | 2 | ||||
| -rw-r--r-- | tests/test_string.h | 2 | ||||
| -rw-r--r-- | tests/test_variant.h | 4 |
20 files changed, 43 insertions, 46 deletions
diff --git a/tests/test_basis.h b/tests/test_basis.h index 05efe33788..db4e0b347f 100644 --- a/tests/test_basis.h +++ b/tests/test_basis.h @@ -33,7 +33,7 @@ #include "core/math/random_number_generator.h" #include "core/os/os.h" -#include "core/ustring.h" +#include "core/string/ustring.h" #include "tests/test_macros.h" diff --git a/tests/test_class_db.h b/tests/test_class_db.h index d0d8136874..29fe837587 100644 --- a/tests/test_class_db.h +++ b/tests/test_class_db.h @@ -33,12 +33,12 @@ #include "core/register_core_types.h" -#include "core/global_constants.h" -#include "core/ordered_hash_map.h" +#include "core/core_constants.h" #include "core/os/os.h" -#include "core/string_name.h" -#include "core/ustring.h" -#include "core/variant.h" +#include "core/string/string_name.h" +#include "core/string/ustring.h" +#include "core/templates/ordered_hash_map.h" +#include "core/variant/variant.h" #include "tests/test_macros.h" @@ -255,7 +255,7 @@ bool arg_default_value_is_assignable_to_type(const Context &p_context, const Var case Variant::VECTOR2: case Variant::RECT2: case Variant::VECTOR3: - case Variant::_RID: + case Variant::RID: case Variant::ARRAY: case Variant::DICTIONARY: case Variant::PACKED_BYTE_ARRAY: @@ -769,16 +769,16 @@ void add_builtin_types(Context &r_context) { } void add_global_enums(Context &r_context) { - int global_constants_count = GlobalConstants::get_global_constant_count(); + int global_constants_count = CoreConstants::get_global_constant_count(); if (global_constants_count > 0) { for (int i = 0; i < global_constants_count; i++) { - StringName enum_name = GlobalConstants::get_global_constant_enum(i); + StringName enum_name = CoreConstants::get_global_constant_enum(i); if (enum_name != StringName()) { ConstantData constant; - constant.name = GlobalConstants::get_global_constant_name(i); - constant.value = GlobalConstants::get_global_constant_value(i); + constant.name = CoreConstants::get_global_constant_name(i); + constant.value = CoreConstants::get_global_constant_value(i); EnumData enum_; enum_.name = enum_name; diff --git a/tests/test_color.h b/tests/test_color.h index dfdc29ec7d..04b66811e3 100644 --- a/tests/test_color.h +++ b/tests/test_color.h @@ -31,7 +31,7 @@ #ifndef TEST_COLOR_H #define TEST_COLOR_H -#include "core/color.h" +#include "core/math/color.h" #include "thirdparty/doctest/doctest.h" @@ -185,9 +185,6 @@ TEST_CASE("[Color] Manipulation methods") { CHECK_MESSAGE( blue.inverted().is_equal_approx(Color(1, 1, 0, 0.4)), "Inverted color should have its red, green and blue components inverted."); - CHECK_MESSAGE( - blue.contrasted().is_equal_approx(Color(0.5, 0.5, 0.5, 0.4)), - "Contrasted pure blue should be fully gray."); const Color purple = Color(0.5, 0.2, 0.5, 0.25); diff --git a/tests/test_command_queue.h b/tests/test_command_queue.h index a66fd3c86e..c3cfa08b61 100644 --- a/tests/test_command_queue.h +++ b/tests/test_command_queue.h @@ -33,12 +33,12 @@ #include "test_command_queue.h" -#include "core/command_queue_mt.h" +#include "core/config/project_settings.h" #include "core/os/mutex.h" #include "core/os/os.h" #include "core/os/semaphore.h" #include "core/os/thread.h" -#include "core/project_settings.h" +#include "core/templates/command_queue_mt.h" #if !defined(NO_THREADS) diff --git a/tests/test_expression.h b/tests/test_expression.h index a3d4877d52..c9cb0158f3 100644 --- a/tests/test_expression.h +++ b/tests/test_expression.h @@ -381,7 +381,7 @@ TEST_CASE("[Expression] Unusual expressions") { ERR_PRINT_OFF; CHECK_MESSAGE( - expression.parse("$1.00 + €5") == OK, + expression.parse("$1.00 + ???5") == OK, "The expression should parse successfully."); CHECK_MESSAGE( int(expression.execute()) == 0, @@ -410,8 +410,8 @@ TEST_CASE("[Expression] Unusual expressions") { "The expression should parse successfully."); ERR_PRINT_OFF; CHECK_MESSAGE( - Math::is_zero_approx(float(expression.execute())), - "`-25.4 / 0` should return 0."); + Math::is_inf(float(expression.execute())), + "`-25.4 / 0` should return inf."); ERR_PRINT_ON; CHECK_MESSAGE( diff --git a/tests/test_gradient.h b/tests/test_gradient.h index 88fe06b3ec..8f28dfd9b4 100644 --- a/tests/test_gradient.h +++ b/tests/test_gradient.h @@ -31,8 +31,8 @@ #ifndef TEST_GRADIENT_H #define TEST_GRADIENT_H -#include "core/class_db.h" -#include "core/color.h" +#include "core/math/color.h" +#include "core/object/class_db.h" #include "scene/resources/gradient.h" #include "thirdparty/doctest/doctest.h" diff --git a/tests/test_gui.cpp b/tests/test_gui.cpp index d46a13d2c0..03c9dfd2ba 100644 --- a/tests/test_gui.cpp +++ b/tests/test_gui.cpp @@ -34,7 +34,7 @@ #include "core/io/image_loader.h" #include "core/os/os.h" -#include "core/print_string.h" +#include "core/string/print_string.h" #include "scene/2d/sprite_2d.h" #include "scene/gui/button.h" #include "scene/gui/control.h" diff --git a/tests/test_list.h b/tests/test_list.h index 7412fbc3c8..adeedaaf3e 100644 --- a/tests/test_list.h +++ b/tests/test_list.h @@ -31,7 +31,7 @@ #ifndef TEST_LIST_H #define TEST_LIST_H -#include "core/list.h" +#include "core/templates/list.h" #include "tests/test_macros.h" diff --git a/tests/test_macros.h b/tests/test_macros.h index 3486c68bb7..05fae128b3 100644 --- a/tests/test_macros.h +++ b/tests/test_macros.h @@ -31,8 +31,8 @@ #ifndef TEST_MACROS_H #define TEST_MACROS_H -#include "core/map.h" -#include "core/variant.h" +#include "core/templates/map.h" +#include "core/variant/variant.h" // See documentation for doctest at: // https://github.com/onqtam/doctest/blob/master/doc/markdown/readme.md#reference diff --git a/tests/test_main.cpp b/tests/test_main.cpp index 871c796513..b4ddf0f1c1 100644 --- a/tests/test_main.cpp +++ b/tests/test_main.cpp @@ -30,7 +30,7 @@ #include "test_main.h" -#include "core/list.h" +#include "core/templates/list.h" #include "test_astar.h" #include "test_basis.h" diff --git a/tests/test_math.cpp b/tests/test_math.cpp index 862535b57e..e745d1609e 100644 --- a/tests/test_math.cpp +++ b/tests/test_math.cpp @@ -36,14 +36,14 @@ #include "core/math/geometry_2d.h" #include "core/math/math_funcs.h" #include "core/math/transform.h" -#include "core/method_ptrcall.h" #include "core/os/file_access.h" #include "core/os/keyboard.h" #include "core/os/os.h" -#include "core/print_string.h" -#include "core/ustring.h" -#include "core/variant.h" -#include "core/vmap.h" +#include "core/string/print_string.h" +#include "core/string/ustring.h" +#include "core/templates/vmap.h" +#include "core/variant/method_ptrcall.h" +#include "core/variant/variant.h" #include "scene/main/node.h" #include "scene/resources/texture.h" #include "servers/rendering/shader_language.h" diff --git a/tests/test_method_bind.h b/tests/test_method_bind.h index f4004c2090..9507a10d3e 100644 --- a/tests/test_method_bind.h +++ b/tests/test_method_bind.h @@ -31,7 +31,7 @@ #ifndef TEST_METHOD_BIND_H #define TEST_METHOD_BIND_H -#include "core/class_db.h" +#include "core/object/class_db.h" #include "tests/test_macros.h" diff --git a/tests/test_oa_hash_map.cpp b/tests/test_oa_hash_map.cpp index 9182f66b61..44717e5690 100644 --- a/tests/test_oa_hash_map.cpp +++ b/tests/test_oa_hash_map.cpp @@ -30,8 +30,8 @@ #include "test_oa_hash_map.h" -#include "core/oa_hash_map.h" #include "core/os/os.h" +#include "core/templates/oa_hash_map.h" namespace TestOAHashMap { diff --git a/tests/test_ordered_hash_map.h b/tests/test_ordered_hash_map.h index 3182c391cb..9f987e8833 100644 --- a/tests/test_ordered_hash_map.h +++ b/tests/test_ordered_hash_map.h @@ -31,10 +31,10 @@ #ifndef TEST_ORDERED_HASH_MAP_H #define TEST_ORDERED_HASH_MAP_H -#include "core/ordered_hash_map.h" #include "core/os/os.h" -#include "core/pair.h" -#include "core/vector.h" +#include "core/templates/ordered_hash_map.h" +#include "core/templates/pair.h" +#include "core/templates/vector.h" #include "tests/test_macros.h" diff --git a/tests/test_physics_2d.cpp b/tests/test_physics_2d.cpp index c82ae920bc..54d373b454 100644 --- a/tests/test_physics_2d.cpp +++ b/tests/test_physics_2d.cpp @@ -30,10 +30,10 @@ #include "test_physics_2d.h" -#include "core/map.h" #include "core/os/main_loop.h" #include "core/os/os.h" -#include "core/print_string.h" +#include "core/string/print_string.h" +#include "core/templates/map.h" #include "scene/resources/texture.h" #include "servers/display_server.h" #include "servers/physics_server_2d.h" diff --git a/tests/test_physics_3d.cpp b/tests/test_physics_3d.cpp index 72de2041e4..1b453be76d 100644 --- a/tests/test_physics_3d.cpp +++ b/tests/test_physics_3d.cpp @@ -30,12 +30,12 @@ #include "test_physics_3d.h" -#include "core/map.h" #include "core/math/math_funcs.h" #include "core/math/quick_hull.h" #include "core/os/main_loop.h" #include "core/os/os.h" -#include "core/print_string.h" +#include "core/string/print_string.h" +#include "core/templates/map.h" #include "servers/display_server.h" #include "servers/physics_server_3d.h" #include "servers/rendering_server.h" diff --git a/tests/test_render.cpp b/tests/test_render.cpp index d936dd72e7..8c5cac694c 100644 --- a/tests/test_render.cpp +++ b/tests/test_render.cpp @@ -35,7 +35,7 @@ #include "core/os/keyboard.h" #include "core/os/main_loop.h" #include "core/os/os.h" -#include "core/print_string.h" +#include "core/string/print_string.h" #include "servers/display_server.h" #include "servers/rendering_server.h" diff --git a/tests/test_shader_lang.cpp b/tests/test_shader_lang.cpp index d363ee22b5..4bfd593279 100644 --- a/tests/test_shader_lang.cpp +++ b/tests/test_shader_lang.cpp @@ -34,7 +34,7 @@ #include "core/os/main_loop.h" #include "core/os/os.h" -#include "core/print_string.h" +#include "core/string/print_string.h" #include "scene/gui/control.h" #include "scene/gui/text_edit.h" #include "servers/rendering/shader_language.h" diff --git a/tests/test_string.h b/tests/test_string.h index b041cb2f49..acdcaccecd 100644 --- a/tests/test_string.h +++ b/tests/test_string.h @@ -38,7 +38,7 @@ #include "core/io/ip_address.h" #include "core/os/main_loop.h" #include "core/os/os.h" -#include "core/ustring.h" +#include "core/string/ustring.h" #ifdef MODULE_REGEX_ENABLED #include "modules/regex/regex.h" diff --git a/tests/test_variant.h b/tests/test_variant.h index a384a3e91f..b7421c29a5 100644 --- a/tests/test_variant.h +++ b/tests/test_variant.h @@ -31,8 +31,8 @@ #ifndef TEST_VARIANT_H #define TEST_VARIANT_H -#include "core/variant.h" -#include "core/variant_parser.h" +#include "core/variant/variant.h" +#include "core/variant/variant_parser.h" #include "tests/test_macros.h" |