diff options
Diffstat (limited to 'src/utils/stringutils_unittest.cc')
-rw-r--r-- | src/utils/stringutils_unittest.cc | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/utils/stringutils_unittest.cc b/src/utils/stringutils_unittest.cc index a8347cdd5..481289087 100644 --- a/src/utils/stringutils_unittest.cc +++ b/src/utils/stringutils_unittest.cc @@ -19,13 +19,17 @@ */ #include "catch.hpp" +#include "logger.h" +#include "utils/physfstools.h" #include "utils/stringutils.h" #include "resources/iteminfo.h" #include "resources/db/itemdb.h" +#include "resources/resourcemanager/resourcemanager.h" + #include "debug.h" TEST_CASE("stringuntils trim 1") @@ -619,6 +623,13 @@ TEST_CASE("stringuntils escapeString") TEST_CASE("stringuntils replaceItemLinks") { + PHYSFS_init("manaplus"); + dirSeparator = "/"; + logger = new Logger(); + ResourceManager::init(); + resourceManager->addToSearchPath("data", Append_false); + resourceManager->addToSearchPath("../data", Append_false); + ItemDB::NamedItemInfos &namedInfos = ItemDB::getNamedItemInfosTest(); ItemDB::ItemInfos &infos = ItemDB::getItemInfosTest(); ItemInfo *info = new ItemInfo; @@ -833,4 +844,6 @@ TEST_CASE("stringuntils replaceItemLinks") replaceItemLinks(str); REQUIRE(str == "[[test name 1 ,test name2[] test name 1]"); } + ResourceManager::deleteInstance(); +// PhysFs::deinit(); } |