summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2015-11-04 09:28:50 +0000
committerCarl Hetherington <cth@carlh.net>2015-11-04 09:28:50 +0000
commit63d0dcf0619d811ceb6b3cbe02974f336cd0759a (patch)
tree13219df481e072edb51f6ea7059a3c4dbfa43956
parent2175471d37831108a25e3e74b956192c64e68e39 (diff)
Try to hack around font finding during unit tests.
-rw-r--r--src/lib/reel_writer.cc6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/lib/reel_writer.cc b/src/lib/reel_writer.cc
index a7e3097f3..c8d848933 100644
--- a/src/lib/reel_writer.cc
+++ b/src/lib/reel_writer.cc
@@ -366,7 +366,11 @@ ReelWriter::create_reel (list<ReferencedReelAsset> const & refs, list<shared_ptr
boost::filesystem::path liberation_normal;
try {
- liberation_normal = shared_path () / "LiberationSans-Regular.ttf";
+ liberation_normal = shared_path() / "LiberationSans-Regular.ttf";
+ if (!boost::filesystem::exists (liberation_normal)) {
+ /* Hack for unit tests */
+ liberation_normal = shared_path() / "fonts" / "LiberationSans-Regular.ttf";
+ }
} catch (boost::filesystem::filesystem_error& e) {
}