summaryrefslogtreecommitdiff
path: root/src/gui
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2017-01-04 18:25:48 +0300
committerAndrei Karas <akaras@inbox.ru>2017-01-04 18:25:48 +0300
commit9fefb2942865846ccb7dbdac4ebd4515b8c851a2 (patch)
treec3e805eb002d03c286de2a3fe37f450f6279f82c /src/gui
parent76ad2d74012c408788473c3b495076c96666b27c (diff)
downloadplus-9fefb2942865846ccb7dbdac4ebd4515b8c851a2.tar.gz
plus-9fefb2942865846ccb7dbdac4ebd4515b8c851a2.tar.bz2
plus-9fefb2942865846ccb7dbdac4ebd4515b8c851a2.tar.xz
plus-9fefb2942865846ccb7dbdac4ebd4515b8c851a2.zip
Add physfs deinit function for unit tests. But not using it for now.
Diffstat (limited to 'src/gui')
-rw-r--r--src/gui/widgets/browserbox_unittest.cc5
-rw-r--r--src/gui/windowmanager_unittest.cc1
2 files changed, 6 insertions, 0 deletions
diff --git a/src/gui/widgets/browserbox_unittest.cc b/src/gui/widgets/browserbox_unittest.cc
index a4438eb64..665d6de3f 100644
--- a/src/gui/widgets/browserbox_unittest.cc
+++ b/src/gui/widgets/browserbox_unittest.cc
@@ -31,6 +31,8 @@
#include "resources/sdlimagehelper.h"
+#include "utils/physfstools.h"
+
#include <physfs.h>
#include "debug.h"
@@ -46,6 +48,8 @@ TEST_CASE("BrowserBox tests", "browserbox")
imageHelper = new SDLImageHelper();
theme = new Theme;
ResourceManager::init();
+ resourceManager->addToSearchPath("data", Append_false);
+ resourceManager->addToSearchPath("../data", Append_false);
ActorSprite::load();
Widget::setGlobalFont(new Font("/usr/share/fonts/truetype/"
"ttf-dejavu/DejaVuSans-Oblique.ttf", 18));
@@ -151,4 +155,5 @@ TEST_CASE("BrowserBox tests", "browserbox")
delete box;
delete client;
client = nullptr;
+// PhysFs::deinit();
}
diff --git a/src/gui/windowmanager_unittest.cc b/src/gui/windowmanager_unittest.cc
index 2230385f2..0f8c5bc15 100644
--- a/src/gui/windowmanager_unittest.cc
+++ b/src/gui/windowmanager_unittest.cc
@@ -673,4 +673,5 @@ TEST_CASE("Windows tests", "windowmanager")
delete2(client);
delete2(serverFeatures);
delete2(inventoryHandler);
+// PhysFs::deinit();
}