summaryrefslogtreecommitdiff
path: root/test/dcp_test.cc
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2020-10-10 18:58:05 +0200
committerCarl Hetherington <cth@carlh.net>2020-10-10 20:14:58 +0200
commitc6cf2a5fb3a30b972c3ad9b10fa4164a66abe840 (patch)
treec9593f70698fc13b725fc4703b2ae6a698fc38a5 /test/dcp_test.cc
parent5292108cb0816789a58ac469114d53ac2a5b5bde (diff)
Fix crash when loading DCPs whose ASSETMAP contains files that are
not mentioned in any PKL (#1855). Back-ported from 4c8cc9e99678a4095772f283ffaaa1d6bd8aaf67 in master.
Diffstat (limited to 'test/dcp_test.cc')
-rw-r--r--test/dcp_test.cc8
1 files changed, 8 insertions, 0 deletions
diff --git a/test/dcp_test.cc b/test/dcp_test.cc
index 2e1344c5..b5d37826 100644
--- a/test/dcp_test.cc
+++ b/test/dcp_test.cc
@@ -327,3 +327,11 @@ BOOST_AUTO_TEST_CASE (dcp_test8)
BOOST_REQUIRE_EQUAL (dcp.cpls().size(), 2);
}
+
+
+/** Test reading a DCP whose ASSETMAP contains assets not used by any PKL */
+BOOST_AUTO_TEST_CASE (dcp_things_in_assetmap_not_in_pkl)
+{
+ dcp::DCP dcp ("test/data/extra_assetmap");
+ BOOST_CHECK_NO_THROW (dcp.read());
+}