summaryrefslogtreecommitdiff
path: root/src/resources/map/maplayer_unittest.cc
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2017-05-18 22:51:52 +0300
committerAndrei Karas <akaras@inbox.ru>2017-05-18 22:53:01 +0300
commit40de3bee0278d6584561a827123bc342934adccb (patch)
tree460ba68f29ec25377ef1971989c4c46e507ea3da /src/resources/map/maplayer_unittest.cc
parentdffd0a4a8e99196ad27f8fde2430b09dd29cac57 (diff)
downloadmv-40de3bee0278d6584561a827123bc342934adccb.tar.gz
mv-40de3bee0278d6584561a827123bc342934adccb.tar.bz2
mv-40de3bee0278d6584561a827123bc342934adccb.tar.xz
mv-40de3bee0278d6584561a827123bc342934adccb.zip
Add support for additional unit test library doctest.
Diffstat (limited to 'src/resources/map/maplayer_unittest.cc')
-rw-r--r--src/resources/map/maplayer_unittest.cc23
1 files changed, 15 insertions, 8 deletions
diff --git a/src/resources/map/maplayer_unittest.cc b/src/resources/map/maplayer_unittest.cc
index 692a4738f..cdd948670 100644
--- a/src/resources/map/maplayer_unittest.cc
+++ b/src/resources/map/maplayer_unittest.cc
@@ -32,6 +32,7 @@
#include "gui/theme.h"
#include "utils/delete2.h"
+#include "utils/env.h"
#include "render/mockgraphics.h"
@@ -45,7 +46,7 @@
#include "debug.h"
-TEST_CASE("MapLayer getTileDrawWidth")
+TEST_CASE("MapLayer getTileDrawWidth", "")
{
Image *const img1 = new Image(32, 32);
Image *const img2 = new Image(32, 32);
@@ -410,7 +411,7 @@ TEST_CASE("MapLayer getTileDrawWidth")
}
-TEST_CASE("MapLayer getEmptyTileDrawWidth")
+TEST_CASE("MapLayer getEmptyTileDrawWidth", "")
{
Image *const img1 = new Image(32, 32);
Image *const img2 = new Image(32, 32);
@@ -538,7 +539,7 @@ TEST_CASE("MapLayer getEmptyTileDrawWidth")
}
-TEST_CASE("MapLayer updateCache")
+TEST_CASE("MapLayer updateCache", "")
{
Image *const img1 = new Image(32, 32);
Image *const img2 = new Image(32, 32);
@@ -902,7 +903,7 @@ TEST_CASE("MapLayer updateCache")
delete img3;
}
-TEST_CASE("MapLayer updateConditionTiles")
+TEST_CASE("MapLayer updateConditionTiles", "")
{
Image *const img1 = new Image(32, 32);
Map *map = nullptr;
@@ -1095,7 +1096,7 @@ TEST_CASE("MapLayer updateConditionTiles")
delete img1;
}
-TEST_CASE("MapLayer draw")
+TEST_CASE("MapLayer draw", "")
{
Image *const img1 = new Image(32, 32);
Image *const img2 = new Image(32, 32);
@@ -1645,8 +1646,10 @@ TEST_CASE("MapLayer draw")
delete mock;
}
-TEST_CASE("MapLayer drawSpecialLayer (specialLayer)")
+TEST_CASE("MapLayer drawSpecialLayer (specialLayer)", "")
{
+ setEnv("SDL_VIDEODRIVER", "dummy");
+
logger = new Logger;
VirtFs::mountDirSilent("data", Append_false);
VirtFs::mountDirSilent("../data", Append_false);
@@ -1997,8 +2000,10 @@ TEST_CASE("MapLayer drawSpecialLayer (specialLayer)")
delete2(logger);
}
-TEST_CASE("MapLayer drawSpecialLayer (tempLayer)")
+TEST_CASE("MapLayer drawSpecialLayer (tempLayer)", "")
{
+ setEnv("SDL_VIDEODRIVER", "dummy");
+
logger = new Logger;
VirtFs::mountDirSilent("data", Append_false);
VirtFs::mountDirSilent("../data", Append_false);
@@ -2355,8 +2360,10 @@ TEST_CASE("MapLayer drawSpecialLayer (tempLayer)")
delete2(logger);
}
-TEST_CASE("MapLayer drawFringe")
+TEST_CASE("MapLayer drawFringe", "")
{
+ setEnv("SDL_VIDEODRIVER", "dummy");
+
logger = new Logger;
VirtFs::mountDirSilent("data", Append_false);
VirtFs::mountDirSilent("../data", Append_false);