summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/test.cc8
1 files changed, 7 insertions, 1 deletions
diff --git a/test/test.cc b/test/test.cc
index 9d444e5cb..c91701e55 100644
--- a/test/test.cc
+++ b/test/test.cc
@@ -94,7 +94,13 @@ TestPaths::TestPaths::private_data ()
return boost::filesystem::path(env);
}
- return boost::filesystem::canonical(boost::filesystem::path ("..") / boost::filesystem::path ("dcpomatic-test-private"));
+ auto relative = boost::filesystem::path ("..") / boost::filesystem::path ("dcpomatic-test-private");
+ if (!boost::filesystem::exists(relative)) {
+ std::cerr << "No private test data found! Tests may fail.\n";
+ return relative;
+ }
+
+ return boost::filesystem::canonical(relative);
}