summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2025-03-19 21:11:03 +0100
committerCarl Hetherington <cth@carlh.net>2025-03-19 21:11:17 +0100
commit4ddd6052b00a07583fda682730dde3c3d1206d1b (patch)
tree6dc16f1ed72016c4f0fc95c25826ff3f1962745b /test
parent0692355b1e4d29b1ccb6e4b83554ffec342a74ad (diff)
Add --auto-crop-threshold option to create CLI.
Diffstat (limited to 'test')
-rw-r--r--test/create_cli_test.cc7
1 files changed, 7 insertions, 0 deletions
diff --git a/test/create_cli_test.cc b/test/create_cli_test.cc
index 6499ef160..5831e6b6f 100644
--- a/test/create_cli_test.cc
+++ b/test/create_cli_test.cc
@@ -201,6 +201,13 @@ BOOST_AUTO_TEST_CASE (create_cli_test)
BOOST_CHECK(!cc.content[1].auto_crop);
BOOST_CHECK(cc.content[2].auto_crop);
+ cc = run("dcpomatic2_create --auto-crop-threshold 42 --auto-crop foo.mp4 bar.mp4 --auto-crop baz.mp4");
+ BOOST_REQUIRE_EQUAL(cc.content.size(), 3U);
+ BOOST_CHECK(cc.content[0].auto_crop);
+ BOOST_CHECK(!cc.content[1].auto_crop);
+ BOOST_CHECK(cc.content[2].auto_crop);
+ BOOST_CHECK_EQUAL(cc.auto_crop_threshold.get_value_or(0), 42);
+
auto pillarbox = TestPaths::private_data() / "pillarbox.png";
cc = run("dcpomatic2_create --auto-crop " + pillarbox.string());
auto film = cc.make_film(error);