diff options
| author | Carl Hetherington <cth@carlh.net> | 2014-06-20 11:55:46 +0100 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2014-06-20 11:55:46 +0100 |
| commit | 194615b5f673214b1e4fc4211364f95eeb96af15 (patch) | |
| tree | ebdeee342e6a428dbe4657307c9e1ca39bf95895 /test/util_test.cc | |
| parent | 2cdecbe2b56233b009f6edfa13033c6ec9d198bf (diff) | |
Add timecode methods to Time
Diffstat (limited to 'test/util_test.cc')
| -rw-r--r-- | test/util_test.cc | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/test/util_test.cc b/test/util_test.cc index 5eb3e27f1..39cc0e6bf 100644 --- a/test/util_test.cc +++ b/test/util_test.cc @@ -88,3 +88,9 @@ BOOST_AUTO_TEST_CASE (divide_with_round_test) BOOST_CHECK_EQUAL (divide_with_round (1000, 500), 2); } + +BOOST_AUTO_TEST_CASE (timecode_test) +{ + DCPTime t = DCPTime::from_seconds (2 * 60 * 60 + 4 * 60 + 31) + DCPTime::from_frames (19, 24); + BOOST_CHECK_EQUAL (t.timecode (24), "02:04:31:19"); +} |
