diff options
Diffstat (limited to 'Swiften/Application/UnitTest/ApplicationPathProviderTest.cpp')
-rw-r--r-- | Swiften/Application/UnitTest/ApplicationPathProviderTest.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/Swiften/Application/UnitTest/ApplicationPathProviderTest.cpp b/Swiften/Application/UnitTest/ApplicationPathProviderTest.cpp index 7cb277a..75b8639 100644 --- a/Swiften/Application/UnitTest/ApplicationPathProviderTest.cpp +++ b/Swiften/Application/UnitTest/ApplicationPathProviderTest.cpp @@ -8,12 +8,14 @@ #include <cppunit/extensions/TestFactoryRegistry.h> #include "Swiften/Application/PlatformApplicationPathProvider.h" +#include "Swiften/Base/String.h" using namespace Swift; class ApplicationPathProviderTest : public CppUnit::TestFixture { CPPUNIT_TEST_SUITE(ApplicationPathProviderTest); CPPUNIT_TEST(testGetSettingsDir); + CPPUNIT_TEST(testGetExecutableDir); CPPUNIT_TEST_SUITE_END(); public: @@ -33,6 +35,12 @@ class ApplicationPathProviderTest : public CppUnit::TestFixture { boost::filesystem::remove(dir); } + + void testGetExecutableDir() { + boost::filesystem::path dir = testling_->getExecutableDir(); + CPPUNIT_ASSERT(boost::filesystem::is_directory(dir)); + CPPUNIT_ASSERT(String(dir.string()).endsWith("UnitTest")); + } private: ApplicationPathProvider* testling_; |