aboutsummaryrefslogtreecommitdiffstats
path: root/config/src/tests/functiontest/functiontest.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'config/src/tests/functiontest/functiontest.cpp')
-rw-r--r--config/src/tests/functiontest/functiontest.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/config/src/tests/functiontest/functiontest.cpp b/config/src/tests/functiontest/functiontest.cpp
index 6541e76e06a..444ba776f27 100644
--- a/config/src/tests/functiontest/functiontest.cpp
+++ b/config/src/tests/functiontest/functiontest.cpp
@@ -95,7 +95,7 @@ struct LazyTestFixture
std::unique_ptr<FunctionTestConfig> _config;
LazyTestFixture(const std::string & dirName)
- : _spec(dirName),
+ : _spec(vespalib::TestApp::GetSourceDirectory() + dirName),
_subscriber(_spec),
_handle(_subscriber.subscribe<FunctionTestConfig>(""))
{
@@ -130,7 +130,7 @@ struct ErrorFixture
};
void attemptLacking(const std::string& param, bool isArray) {
- std::ifstream in("defaultvalues/function-test.cfg", std::ios_base::in);
+ std::ifstream in(vespalib::TestApp::GetSourceDirectory() + "defaultvalues/function-test.cfg", std::ios_base::in);
std::ostringstream config;
std::string s;
while (std::getline(in, s)) {
@@ -172,7 +172,7 @@ TEST_F("testVariableAccess", TestFixture("variableaccess")) {
TEST("test variable access from slime") {
vespalib::Slime slime;
- std::string json(readFile("slime-payload.json"));
+ std::string json(readFile(vespalib::TestApp::GetSourceDirectory() + "slime-payload.json"));
vespalib::slime::JsonFormat::decode(json, slime);
FunctionTestConfig config(config::ConfigPayload(slime.get()));
checkVariableAccess(config);