summaryrefslogtreecommitdiffstats
path: root/vespalib/src/tests/text
diff options
context:
space:
mode:
authorArnstein Ressem <aressem@gmail.com>2016-11-02 23:26:40 +0100
committerArnstein Ressem <aressem@gmail.com>2016-11-02 23:26:40 +0100
commit99480b4d72abf3688060d7643816680a30963f74 (patch)
tree966d8494bca9292e6be2877d91ed838953856f0f /vespalib/src/tests/text
parent3d18773cf5357250cb2d35d6e8c13477db6e20a3 (diff)
Removed TestApp::GetSourceDirectory
Diffstat (limited to 'vespalib/src/tests/text')
-rw-r--r--vespalib/src/tests/text/lowercase/lowercase_test.cpp3
-rw-r--r--vespalib/src/tests/text/utf8/utf8_test.cpp4
2 files changed, 5 insertions, 2 deletions
diff --git a/vespalib/src/tests/text/lowercase/lowercase_test.cpp b/vespalib/src/tests/text/lowercase/lowercase_test.cpp
index 39ae5c0aea0..0d2514a0a21 100644
--- a/vespalib/src/tests/text/lowercase/lowercase_test.cpp
+++ b/vespalib/src/tests/text/lowercase/lowercase_test.cpp
@@ -2,6 +2,7 @@
#include <vespa/fastos/fastos.h>
#include <vespa/log/log.h>
LOG_SETUP("lowercase_test");
+#include <vespa/vespalib/testkit/test_kit.h>
#include <vespa/vespalib/testkit/testapp.h>
#include <vespa/vespalib/text/lowercase.h>
#include <iostream>
@@ -20,7 +21,7 @@ Test::Main()
EXPECT_EQUAL((int8_t)'a', LowerCase::convert((int8_t)'A'));
EXPECT_EQUAL((uint8_t)'a', LowerCase::convert((uint8_t)'A'));
- std::ifstream yellData(vespalib::TestApp::GetSourceDirectory() + "yell-want.dat");
+ std::ifstream yellData(TEST_PATH("yell-want.dat"));
EXPECT_TRUE(yellData.good());
diff --git a/vespalib/src/tests/text/utf8/utf8_test.cpp b/vespalib/src/tests/text/utf8/utf8_test.cpp
index e88fe756e40..fd58dbfa044 100644
--- a/vespalib/src/tests/text/utf8/utf8_test.cpp
+++ b/vespalib/src/tests/text/utf8/utf8_test.cpp
@@ -2,8 +2,10 @@
#include <vespa/fastos/fastos.h>
#include <vespa/log/log.h>
LOG_SETUP("utf8_test");
+#include <vespa/vespalib/testkit/test_kit.h>
#include <vespa/vespalib/testkit/testapp.h>
#include <vespa/vespalib/text/utf8.h>
+
#if 0
#include <vespa/fastlib/text/unicodeutil.h>
#endif
@@ -54,7 +56,7 @@ Test::Main()
{
// read data produced from Java program
- int fd = ::open((vespalib::TestApp::GetSourceDirectory() + "regular-utf8.dat").c_str(), O_RDONLY);
+ int fd = ::open(TEST_PATH("regular-utf8.dat").c_str(), O_RDONLY);
ASSERT_TRUE(fd > 0);
vespalib::string data;
data.clear();