diff options
Diffstat (limited to 'src/unittests/resources/map')
6 files changed, 44 insertions, 4 deletions
diff --git a/src/unittests/resources/map/maplayer/draw.cc b/src/unittests/resources/map/maplayer/draw.cc index ac7fba9b7..5e6cfdddf 100644 --- a/src/unittests/resources/map/maplayer/draw.cc +++ b/src/unittests/resources/map/maplayer/draw.cc @@ -25,8 +25,6 @@ #include "unittests/render/mockgraphics.h" -#include "utils/delete2.h" - #include "resources/image/image.h" #include "resources/map/map.h" diff --git a/src/unittests/resources/map/maplayer/drawfringenormal.cc b/src/unittests/resources/map/maplayer/drawfringenormal.cc index 6ab0a395c..4ec72484b 100644 --- a/src/unittests/resources/map/maplayer/drawfringenormal.cc +++ b/src/unittests/resources/map/maplayer/drawfringenormal.cc @@ -20,6 +20,9 @@ #include "unittests/unittests.h" +#include "configmanager.h" +#include "configuration.h" +#include "dirs.h" #include "graphicsmanager.h" #include "being/localplayer.h" @@ -65,6 +68,12 @@ TEST_CASE("MapLayer drawFringe normal", "") graphicsManager.createWindow(640, 480, 0, SDL_ANYFORMAT | SDL_SWSURFACE); #endif // USE_SDL2 + Dirs::initRootDir(); + Dirs::initHomeDir(); + + setBrandingDefaults(branding); + ConfigManager::initConfiguration(); + theme = new Theme; Theme::selectSkin(); diff --git a/src/unittests/resources/map/maplayer/drawfringesimple.cc b/src/unittests/resources/map/maplayer/drawfringesimple.cc index 6a362b8aa..8c3457e8f 100644 --- a/src/unittests/resources/map/maplayer/drawfringesimple.cc +++ b/src/unittests/resources/map/maplayer/drawfringesimple.cc @@ -20,6 +20,9 @@ #include "unittests/unittests.h" +#include "configmanager.h" +#include "configuration.h" +#include "dirs.h" #include "graphicsmanager.h" #include "being/localplayer.h" @@ -62,6 +65,12 @@ TEST_CASE("MapLayer drawFringe simple", "") graphicsManager.createWindow(640, 480, 0, SDL_ANYFORMAT | SDL_SWSURFACE); #endif // USE_SDL2 + Dirs::initRootDir(); + Dirs::initHomeDir(); + + setBrandingDefaults(branding); + ConfigManager::initConfiguration(); + theme = new Theme; Theme::selectSkin(); diff --git a/src/unittests/resources/map/maplayer/drawspeciallayer1.cc b/src/unittests/resources/map/maplayer/drawspeciallayer1.cc index 3224eb5ef..2927deb48 100644 --- a/src/unittests/resources/map/maplayer/drawspeciallayer1.cc +++ b/src/unittests/resources/map/maplayer/drawspeciallayer1.cc @@ -20,6 +20,9 @@ #include "unittests/unittests.h" +#include "configmanager.h" +#include "configuration.h" +#include "dirs.h" #include "graphicsmanager.h" #include "enums/resources/map/mapitemtype.h" @@ -59,6 +62,12 @@ TEST_CASE("MapLayer drawSpecialLayer (specialLayer)", "") graphicsManager.createWindow(640, 480, 0, SDL_ANYFORMAT | SDL_SWSURFACE); #endif // USE_SDL2 + Dirs::initRootDir(); + Dirs::initHomeDir(); + + setBrandingDefaults(branding); + ConfigManager::initConfiguration(); + Map *map = nullptr; MapLayer *layer = nullptr; SpecialLayer *specialLayer = nullptr; diff --git a/src/unittests/resources/map/maplayer/drawspeciallayer2.cc b/src/unittests/resources/map/maplayer/drawspeciallayer2.cc index 0092b2019..ec101a099 100644 --- a/src/unittests/resources/map/maplayer/drawspeciallayer2.cc +++ b/src/unittests/resources/map/maplayer/drawspeciallayer2.cc @@ -20,6 +20,9 @@ #include "unittests/unittests.h" +#include "configmanager.h" +#include "configuration.h" +#include "dirs.h" #include "graphicsmanager.h" #include "enums/resources/map/mapitemtype.h" @@ -59,6 +62,12 @@ TEST_CASE("MapLayer drawSpecialLayer (tempLayer)", "") graphicsManager.createWindow(640, 480, 0, SDL_ANYFORMAT | SDL_SWSURFACE); #endif // USE_SDL2 + Dirs::initRootDir(); + Dirs::initHomeDir(); + + setBrandingDefaults(branding); + ConfigManager::initConfiguration(); + Map *map = nullptr; MapLayer *layer = nullptr; SpecialLayer *specialLayer = nullptr; diff --git a/src/unittests/resources/map/speciallayer.cc b/src/unittests/resources/map/speciallayer.cc index ef9b79e48..49b50c932 100644 --- a/src/unittests/resources/map/speciallayer.cc +++ b/src/unittests/resources/map/speciallayer.cc @@ -21,6 +21,8 @@ #include "unittests/unittests.h" #include "client.h" +#include "configmanager.h" +#include "configuration.h" #include "dirs.h" #include "graphicsmanager.h" @@ -65,12 +67,16 @@ TEST_CASE("SpecialLayer updateCache", "") #endif // USE_SDL2 userPalette = new UserPalette; - theme = new Theme; - Theme::selectSkin(); Dirs::initRootDir(); Dirs::initHomeDir(); + setBrandingDefaults(branding); + ConfigManager::initConfiguration(); + + theme = new Theme; + Theme::selectSkin(); + ActorSprite::load(); SpecialLayer *layer = nullptr; |