diff options
| author | Carl Hetherington <cth@carlh.net> | 2016-05-24 23:02:38 +0100 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2016-05-24 23:02:38 +0100 |
| commit | cb7c3db37d196b6e9ddad60937bd5314a95eadb2 (patch) | |
| tree | b686e05142b39208e4af8ab0a01e3b47c5256378 /test/read_dcp_test.cc | |
| parent | 096b175a661234d9e02a852cce9f56c4577b8259 (diff) | |
| parent | 85c699d29aab7ca7f7218b3f7f859e10c9025e37 (diff) | |
Merge branch '1.0' of ssh://main.carlh.net/home/carl/git/libdcp into 1.0
Diffstat (limited to 'test/read_dcp_test.cc')
| -rw-r--r-- | test/read_dcp_test.cc | 22 |
1 files changed, 20 insertions, 2 deletions
diff --git a/test/read_dcp_test.cc b/test/read_dcp_test.cc index 097d0aa9..60aa3591 100644 --- a/test/read_dcp_test.cc +++ b/test/read_dcp_test.cc @@ -18,14 +18,15 @@ */ #include <boost/test/unit_test.hpp> +#include <boost/optional/optional_io.hpp> #include "dcp.h" #include "cpl.h" using std::list; using boost::shared_ptr; -/** Read DCP that is in git and make sure that basic stuff is read in correctly */ -BOOST_AUTO_TEST_CASE (read_dcp) +/** Read a SMPTE DCP that is in git and make sure that basic stuff is read in correctly */ +BOOST_AUTO_TEST_CASE (read_dcp_test1) { dcp::DCP d ("test/ref/DCP/dcp_test1"); d.read (); @@ -35,4 +36,21 @@ BOOST_AUTO_TEST_CASE (read_dcp) BOOST_CHECK_EQUAL (cpls.front()->annotation_text(), "A Test DCP"); BOOST_CHECK_EQUAL (cpls.front()->content_kind(), dcp::FEATURE); + BOOST_REQUIRE (d.standard()); + BOOST_CHECK_EQUAL (d.standard(), dcp::SMPTE); +} + +/** Read an Interop DCP that is in git and make sure that basic stuff is read in correctly */ +BOOST_AUTO_TEST_CASE (read_dcp_test2) +{ + dcp::DCP d ("test/ref/DCP/dcp_test3"); + d.read (); + + list<shared_ptr<dcp::CPL> > cpls = d.cpls (); + BOOST_CHECK_EQUAL (cpls.size(), 1); + + BOOST_CHECK_EQUAL (cpls.front()->annotation_text(), "Test_FTR-1_F-119_10_2K_20160524_IOP_OV"); + BOOST_CHECK_EQUAL (cpls.front()->content_kind(), dcp::FEATURE); + BOOST_REQUIRE (d.standard()); + BOOST_CHECK_EQUAL (d.standard(), dcp::INTEROP); } |
