diff options
| author | Carl Hetherington <cth@carlh.net> | 2025-01-14 23:50:38 +0100 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2025-01-19 22:48:28 +0100 |
| commit | eb28997f188c905af40054e4139251ebf1756ae4 (patch) | |
| tree | 91214593633d2a391587e46e2f2375d2fc47ad3b /test | |
| parent | d4024848dfe293b06440d20a9f48894b2b008316 (diff) | |
Make MainSoundConfiguration behave "correctly" with badly-formatted strings.
Add some documentation for a design "principle" when handling malformatted
data, and make MainSoundConfiguration adhere to that.
Diffstat (limited to 'test')
| -rw-r--r-- | test/cpl_metadata_test.cc | 1 | ||||
| -rw-r--r-- | test/verify_test.cc | 5 |
2 files changed, 4 insertions, 2 deletions
diff --git a/test/cpl_metadata_test.cc b/test/cpl_metadata_test.cc index a24fd7e0..2fd7476a 100644 --- a/test/cpl_metadata_test.cc +++ b/test/cpl_metadata_test.cc @@ -184,7 +184,6 @@ BOOST_AUTO_TEST_CASE(main_sound_configuration_test6) BOOST_AUTO_TEST_CASE(main_sound_configuration_test_case_insensitive) { dcp::MainSoundConfiguration msc("51/L,-,C,LFE,LS,RS,HI,VIN"); - BOOST_CHECK_EQUAL(msc.to_string(), "51/L,-,C,LFE,Ls,Rs,HI,VIN"); BOOST_CHECK_EQUAL(msc.channels(), 8); BOOST_CHECK_EQUAL(msc.field(), dcp::MCASoundField::FIVE_POINT_ONE); BOOST_CHECK_EQUAL(msc.mapping(0).get(), dcp::Channel::LEFT); diff --git a/test/verify_test.cc b/test/verify_test.cc index 79db9f95..8a3d5676 100644 --- a/test/verify_test.cc +++ b/test/verify_test.cc @@ -5456,7 +5456,10 @@ BOOST_AUTO_TEST_CASE(verify_invalid_main_sound_configuration) ).set_cpl_id(cpl->id()), ok(dcp::VerificationNote::Code::VALID_CONTENT_VERSION_LABEL_TEXT, cpl->content_version()->label_text, cpl), dcp::VerificationNote( - dcp::VerificationNote::Type::ERROR, dcp::VerificationNote::Code::INVALID_MAIN_SOUND_CONFIGURATION, std::string{"MainSoundConfiguration has 6 channels but sound assets have 2"}, canonical(find_cpl(path)) + dcp::VerificationNote::Type::ERROR, + dcp::VerificationNote::Code::INVALID_MAIN_SOUND_CONFIGURATION, + std::string{"MainSoundConfiguration has 6 channels but sound assets have 2"}, + canonical(find_cpl(path)) ).set_cpl_id(cpl->id()) }); } |
