summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/SCsub6
-rw-r--r--tests/core/io/test_image.h6
-rw-r--r--tests/scene/test_viewport.h2
3 files changed, 5 insertions, 9 deletions
diff --git a/tests/SCsub b/tests/SCsub
index c59ce69b92..d96a1142e4 100644
--- a/tests/SCsub
+++ b/tests/SCsub
@@ -13,10 +13,8 @@ env_tests = env.Clone()
if env_tests["platform"] == "windows":
env_tests.Append(CPPDEFINES=[("DOCTEST_THREAD_LOCAL", "")])
-# Increase number of addressable sections in object files
-# due to doctest's heavy use of templates and macros.
-if env_tests.msvc:
- env_tests.Append(CCFLAGS=["/bigobj"])
+if env["disable_exceptions"]:
+ env_tests.Append(CPPDEFINES=["DOCTEST_CONFIG_NO_EXCEPTIONS_BUT_WITH_ALL_ASSERTS"])
env_tests.add_source_files(env.tests_sources, "*.cpp")
diff --git a/tests/core/io/test_image.h b/tests/core/io/test_image.h
index 92ab166ae8..1897971113 100644
--- a/tests/core/io/test_image.h
+++ b/tests/core/io/test_image.h
@@ -262,9 +262,7 @@ TEST_CASE("[Image] Modifying pixels of an image") {
for (const Rect2i &rect : rects) {
Ref<Image> img = memnew(Image(img_width, img_height, false, Image::FORMAT_RGBA8));
- CHECK_NOTHROW_MESSAGE(
- img->fill_rect(rect, Color(1, 1, 1, 1)),
- "fill_rect() shouldn't throw for any rect.");
+ img->fill_rect(rect, Color(1, 1, 1, 1));
for (int y = 0; y < img->get_height(); y++) {
for (int x = 0; x < img->get_width(); x++) {
if (rect.abs().has_point(Point2(x, y))) {
@@ -317,7 +315,7 @@ TEST_CASE("[Image] Modifying pixels of an image") {
// Pre-multiply Alpha then Convert from RGBA to L8, checking alpha
{
Ref<Image> gray_image = memnew(Image(3, 3, false, Image::FORMAT_RGBA8));
- CHECK_NOTHROW_MESSAGE(gray_image->fill_rect(Rect2i(0, 0, 3, 3), Color(1, 1, 1, 0)), "fill_rect() shouldn't throw for any rect.");
+ gray_image->fill_rect(Rect2i(0, 0, 3, 3), Color(1, 1, 1, 0));
gray_image->set_pixel(1, 1, Color(1, 1, 1, 1));
gray_image->set_pixel(1, 2, Color(0.5, 0.5, 0.5, 0.5));
gray_image->set_pixel(2, 1, Color(0.25, 0.05, 0.5, 1.0));
diff --git a/tests/scene/test_viewport.h b/tests/scene/test_viewport.h
index ab17459a41..dd4786977e 100644
--- a/tests/scene/test_viewport.h
+++ b/tests/scene/test_viewport.h
@@ -226,7 +226,7 @@ TEST_CASE("[SceneTree][Viewport] Controls and InputEvent handling") {
SUBCASE("[Viewport][GuiInputEvent] nullptr as argument doesn't lead to a crash.") {
ERR_PRINT_OFF;
- CHECK_NOTHROW(root->push_input(nullptr));
+ root->push_input(nullptr);
ERR_PRINT_ON;
}