summaryrefslogtreecommitdiff
path: root/test/dcp_test.cc
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2022-04-25 23:31:13 +0200
committerCarl Hetherington <cth@carlh.net>2022-04-25 23:31:13 +0200
commitef9671811920cbef50f0f01d063eab418de8925e (patch)
tree0161463370f4a995f5e1b275b642de534b68f6d4 /test/dcp_test.cc
parent98227f0ca88034061092cd2a179c5cade2924f50 (diff)
Tidy up write_xml() API a little.
Diffstat (limited to 'test/dcp_test.cc')
-rw-r--r--test/dcp_test.cc30
1 files changed, 22 insertions, 8 deletions
diff --git a/test/dcp_test.cc b/test/dcp_test.cc
index 0c246ad4..7618f2ee 100644
--- a/test/dcp_test.cc
+++ b/test/dcp_test.cc
@@ -67,9 +67,12 @@ BOOST_AUTO_TEST_CASE (dcp_test1)
{
RNGFixer fixer;
- make_simple("build/test/DCP/dcp_test1")->write_xml(
- "OpenDCP 0.0.25", "OpenDCP 0.0.25", "2012-07-17T04:45:18+00:00", "A Test DCP"
- );
+ auto dcp = make_simple("build/test/DCP/dcp_test1");
+ dcp->set_issuer("OpenDCP 0.0.25");
+ dcp->set_creator("OpenDCP 0.0.25");
+ dcp->set_issue_date("2012-07-17T04:45:18+00:00");
+ dcp->set_annotation_text("A Test DCP");
+ dcp->write_xml();
/* build/test/DCP/dcp_test1 is checked against test/ref/DCP/dcp_test1 by run/tests */
}
@@ -138,7 +141,11 @@ BOOST_AUTO_TEST_CASE (dcp_test2)
d.add (cpl);
- d.write_xml ("OpenDCP 0.0.25", "OpenDCP 0.0.25", "2012-07-17T04:45:18+00:00", "Created by libdcp");
+ d.set_issuer("OpenDCP 0.0.25");
+ d.set_creator("OpenDCP 0.0.25");
+ d.set_issue_date("2012-07-17T04:45:18+00:00");
+ d.set_annotation_text("Created by libdcp");
+ d.write_xml();
/* build/test/DCP/dcp_test2 is checked against test/ref/DCP/dcp_test2 by run/tests */
}
@@ -321,7 +328,11 @@ BOOST_AUTO_TEST_CASE (dcp_test5)
d.add (cpl);
- d.write_xml ("OpenDCP 0.0.25", "OpenDCP 0.0.25", "2012-07-17T04:45:18+00:00", "Created by libdcp");
+ d.set_issuer("OpenDCP 0.0.25");
+ d.set_creator("OpenDCP 0.0.25");
+ d.set_issue_date("2012-07-17T04:45:18+00:00");
+ d.set_annotation_text("Created by libdcp");
+ d.write_xml();
/* build/test/DCP/dcp_test5 is checked against test/ref/DCP/dcp_test5 by run/tests */
}
@@ -345,9 +356,12 @@ BOOST_AUTO_TEST_CASE (dcp_test7)
{
RNGFixer fix;
- make_simple("build/test/DCP/dcp_test7", 1, 24, dcp::Standard::INTEROP)->write_xml(
- "OpenDCP 0.0.25", "OpenDCP 0.0.25", "2012-07-17T04:45:18+00:00", "Created by libdcp"
- );
+ auto dcp = make_simple("build/test/DCP/dcp_test7", 1, 24, dcp::Standard::INTEROP);
+ dcp->set_issuer("OpenDCP 0.0.25");
+ dcp->set_creator("OpenDCP 0.0.25");
+ dcp->set_issue_date("2012-07-17T04:45:18+00:00");
+ dcp->set_annotation_text("Created by libdcp");
+ dcp->write_xml();
/* build/test/DCP/dcp_test7 is checked against test/ref/DCP/dcp_test7 by run/tests */
}