Use $HOME rather than hard-coded user name.
[dcpomatic.git] / test / file_extension_test.cc
index 2c9020b6cb61c1eed253a40a4639ca59700e631e..87b55114a95db95649bb626fab89e5962ff74798 100644 (file)
 */
 
 
+#include "lib/content.h"
 #include "lib/content_factory.h"
 #include "lib/film.h"
+#include "lib/text_content.h"
 #include "test.h"
 #include <boost/test/unit_test.hpp>
 
  */
 BOOST_AUTO_TEST_CASE (interop_file_extension_test)
 {
-       auto video = content_factory("test/data/flat_red.png").front();
-       auto audio = content_factory("test/data/sine_440.wav").front();
-       auto sub = content_factory("test/data/15s.srt").front();
+       auto video = content_factory("test/data/flat_red.png")[0];
+       auto audio = content_factory("test/data/sine_440.wav")[0];
+       auto sub = content_factory("test/data/15s.srt")[0];
        auto film = new_test_film2("interop_file_extension_test", { video, audio, sub });
        film->set_interop(true);
+       sub->only_text()->set_language(dcp::LanguageTag("de"));
 
        make_and_verify_dcp(
                film, {
@@ -56,9 +59,9 @@ BOOST_AUTO_TEST_CASE (interop_file_extension_test)
 
 BOOST_AUTO_TEST_CASE (smpte_file_extension_test)
 {
-       auto video = content_factory("test/data/flat_red.png").front();
-       auto audio = content_factory("test/data/sine_440.wav").front();
-       auto sub = content_factory("test/data/15s.srt").front();
+       auto video = content_factory("test/data/flat_red.png")[0];
+       auto audio = content_factory("test/data/sine_440.wav")[0];
+       auto sub = content_factory("test/data/15s.srt")[0];
        auto film = new_test_film2("smpte_file_extension_test", { video, audio, sub });
        film->set_interop(false);