Various comment fixes to tests.
authorCarl Hetherington <cth@carlh.net>
Tue, 29 Apr 2014 19:57:02 +0000 (20:57 +0100)
committerCarl Hetherington <cth@carlh.net>
Tue, 29 Apr 2014 19:57:02 +0000 (20:57 +0100)
29 files changed:
test/README [new file with mode: 0644]
test/audio_delay_test.cc
test/black_fill_test.cc
test/ffmpeg_decoder_seek_test.cc
test/ffmpeg_decoder_sequential_test.cc
test/ffmpeg_examiner_test.cc
test/ffmpeg_pts_offset.cc [deleted file]
test/ffmpeg_pts_offset_test.cc [new file with mode: 0644]
test/file_group_test.cc
test/film_metadata_test.cc
test/frame_rate_test.cc
test/image_test.cc
test/job_test.cc
test/make_black_test.cc
test/pixel_formats_test.cc
test/player_silence_padding_test.cc
test/ratio_test.cc
test/recover_test.cc
test/repeat_frame_test.cc
test/resampler_test.cc
test/scaling_test.cc
test/silence_padding_test.cc
test/skip_frame_test.cc
test/stream_test.cc
test/subrip_test.cc
test/test.cc
test/threed_test.cc
test/util_test.cc
test/wscript

diff --git a/test/README b/test/README
new file mode 100644 (file)
index 0000000..aac515b
--- /dev/null
@@ -0,0 +1,48 @@
+DCP-o-matic unit tests
+----------------------
+
+They can be grouped roughly into the following:
+
+* Self-contained tests of single classes / method sets
+
+AudioAnalysis:    audio_analysis_test
+AudioMapping:     audio_mapping_test
+ColourConversion: colour_conversion_test
+FileGroup:        file_group_test
+Image:            image_test, pixel_formats_test, make_black_test
+Job/JobManager:   job_test
+SubRip:           subrip_test
+Ratio:            ratio_test
+Resampler:       resampler_test
+util.cc:          util_test
+
+* "Complete" builds of DCPs with various characteristics, aiming
+to test broad areas of code
+
+4k_test
+threed_test
+
+* Tests of fairly specific areas
+
+audio_delay_test
+black_fill_test
+client_server_test
+film_metadata_test
+frame_rate_test
+player_silence_padding_test
+recover_test
+repeat_frame_test
+scaling_test
+silence_padding_test
+skip_frame_test
+
+  - FFmpeg decoding
+
+  ffmpeg_audio_test
+  ffmpeg_dcp_test
+  ffmpeg_decoder_seek_test
+  ffmpeg_decoder_sequential_test
+  ffmpeg_examiner_test
+  ffmpeg_pts_offset_test
+  seek_zero_test.cc
+  stream_test
index 8f4ca836a0feba8ccf116da4f933c0847efe688c..87e6071a08bdb7e8717ce9726ed6301e8846365a 100644 (file)
@@ -1,5 +1,5 @@
 /*
-    Copyright (C) 2013 Carl Hetherington <cth@carlh.net>
+    Copyright (C) 2013-2014 Carl Hetherington <cth@carlh.net>
 
     This program is free software; you can redistribute it and/or modify
     it under the terms of the GNU General Public License as published by
index ef768b9a49daa2d7fd1ff1debfe671335504ca18..7741277a595e753cacd76ffdff1b5a2f67b3cf0f 100644 (file)
@@ -1,5 +1,5 @@
 /*
-    Copyright (C) 2013 Carl Hetherington <cth@carlh.net>
+    Copyright (C) 2013-2014 Carl Hetherington <cth@carlh.net>
 
     This program is free software; you can redistribute it and/or modify
     it under the terms of the GNU General Public License as published by
index 76124786e8bb611be7fc44c30bf6a17d50ef3877..dd80765f419e6e4e3bc9995fd602271f9e934758 100644 (file)
 
 */
 
+/** @file  test/ffmpeg_decoder_seek_test.cc
+ *  @brief Check that get_video() returns the frame indexes that we ask for
+ *  for FFmpegDecoder.
+ *
+ *  This doesn't check that the contents of those frames are right, which
+ *  it probably should.
+ */
+
 #include <vector>
 #include <boost/test/unit_test.hpp>
 #include <boost/filesystem.hpp>
index 96de9be2784e1ce5830ee7d5cf1fe180815181c2..48b9b6b3bb27d8e140c706baa1dc37ebdf38fb0a 100644 (file)
 
 */
 
+/** @file  test/ffmpeg_decoder_sequential_test.cc
+ *  @brief Check that the FFmpeg decoder produces sequential frames without gaps or dropped frames;
+ *  (dropped frames being checked by assert() in VideoDecoder).  Also that the decoder picks up frame rates correctly.
+ */
+
 #include <boost/test/unit_test.hpp>
 #include <boost/filesystem.hpp>
 #include "lib/ffmpeg_content.h"
@@ -64,13 +69,10 @@ test (boost::filesystem::path file, float fps, int first)
        BOOST_CHECK_EQUAL (decoder.test_gaps, 0);
 }
 
-/** Check that the FFmpeg decoder produces sequential frames without gaps or dropped frames;
- *  (dropped frames being checked by assert() in VideoDecoder).  Also that the decoder picks up frame rates correctly.
- */
 BOOST_AUTO_TEST_CASE (ffmpeg_decoder_sequential_test)
 {
-       //test ("boon_telly.mkv", 29.97, 0);
-       //test ("Sintel_Trailer1.480p.DivX_Plus_HD.mkv", 24, 0);
+       test ("boon_telly.mkv", 29.97, 0);
+       test ("Sintel_Trailer1.480p.DivX_Plus_HD.mkv", 24, 0);
        test ("prophet_clip.mkv", 23.976, 12);
 }
 
index 00a01e657f03e340c42045f2569b1f07dc820c44..d72226a6f68a173ed8e53ae4b788acdf438049e4 100644 (file)
 
 */
 
+/** @file  test/ffmpeg_examiner_test.cc
+ *  @brief Check that the FFmpegExaminer can extract the first video and audio time
+ *  correctly from data/count300bd24.m2ts.
+ */
+
 #include <boost/test/unit_test.hpp>
 #include "lib/ffmpeg_examiner.h"
 #include "lib/ffmpeg_content.h"
diff --git a/test/ffmpeg_pts_offset.cc b/test/ffmpeg_pts_offset.cc
deleted file mode 100644 (file)
index dc391ed..0000000
+++ /dev/null
@@ -1,76 +0,0 @@
-/*
-    Copyright (C) 2013 Carl Hetherington <cth@carlh.net>
-
-    This program is free software; you can redistribute it and/or modify
-    it under the terms of the GNU General Public License as published by
-    the Free Software Foundation; either version 2 of the License, or
-    (at your option) any later version.
-
-    This program is distributed in the hope that it will be useful,
-    but WITHOUT ANY WARRANTY; without even the implied warranty of
-    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-    GNU General Public License for more details.
-
-    You should have received a copy of the GNU General Public License
-    along with this program; if not, write to the Free Software
-    Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-
-*/
-
-#include <boost/test/unit_test.hpp>
-#include "lib/film.h"
-#include "lib/ffmpeg_decoder.h"
-#include "lib/ffmpeg_content.h"
-#include "test.h"
-
-using boost::shared_ptr;
-
-BOOST_AUTO_TEST_CASE (ffmpeg_pts_offset_test)
-{
-       shared_ptr<Film> film = new_test_film ("ffmpeg_pts_offset_test");
-       shared_ptr<FFmpegContent> content (new FFmpegContent (film, "test/data/test.mp4"));
-       content->_audio_stream.reset (new FFmpegAudioStream);
-       content->_video_frame_rate = 24;
-
-       {
-               /* Sound == video so no offset required */
-               content->_first_video = ContentTime ();
-               content->_audio_stream->first_audio = ContentTime ();
-               FFmpegDecoder decoder (content, film->log());
-               BOOST_CHECK_EQUAL (decoder._pts_offset, ContentTime ());
-       }
-
-       {
-               /* Common offset should be removed */
-               content->_first_video = ContentTime::from_seconds (600);
-               content->_audio_stream->first_audio = ContentTime::from_seconds (600);
-               FFmpegDecoder decoder (content, film->log());
-               BOOST_CHECK_EQUAL (decoder._pts_offset, ContentTime::from_seconds (-600));
-       }
-
-       {
-               /* Video is on a frame boundary */
-               content->_first_video = ContentTime::from_frames (1, 24);
-               content->_audio_stream->first_audio = ContentTime ();
-               FFmpegDecoder decoder (content, film->log());
-               BOOST_CHECK_EQUAL (decoder._pts_offset, ContentTime ());
-       }
-
-       {
-               /* Video is off a frame boundary */
-               double const frame = 1.0 / 24.0;
-               content->_first_video = ContentTime::from_seconds (frame + 0.0215);
-               content->_audio_stream->first_audio = ContentTime ();
-               FFmpegDecoder decoder (content, film->log());
-               BOOST_CHECK_CLOSE (decoder._pts_offset.seconds(), (frame - 0.0215), 0.00001);
-       }
-
-       {
-               /* Video is off a frame boundary and both have a common offset */
-               double const frame = 1.0 / 24.0;
-               content->_first_video = ContentTime::from_seconds (frame + 0.0215 + 4.1);
-               content->_audio_stream->first_audio = ContentTime::from_seconds (4.1);
-               FFmpegDecoder decoder (content, film->log());
-               BOOST_CHECK_EQUAL (decoder._pts_offset.seconds(), (frame - 0.0215) - 4.1);
-       }
-}
diff --git a/test/ffmpeg_pts_offset_test.cc b/test/ffmpeg_pts_offset_test.cc
new file mode 100644 (file)
index 0000000..9a9785d
--- /dev/null
@@ -0,0 +1,80 @@
+/*
+    Copyright (C) 2013-2014 Carl Hetherington <cth@carlh.net>
+
+    This program is free software; you can redistribute it and/or modify
+    it under the terms of the GNU General Public License as published by
+    the Free Software Foundation; either version 2 of the License, or
+    (at your option) any later version.
+
+    This program is distributed in the hope that it will be useful,
+    but WITHOUT ANY WARRANTY; without even the implied warranty of
+    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+    GNU General Public License for more details.
+
+    You should have received a copy of the GNU General Public License
+    along with this program; if not, write to the Free Software
+    Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+
+*/
+
+/** @file  test/ffmpeg_pts_offset_test.cc
+ *  @brief Check the computation of _pts_offset in FFmpegDecoder.
+ */
+
+#include <boost/test/unit_test.hpp>
+#include "lib/film.h"
+#include "lib/ffmpeg_decoder.h"
+#include "lib/ffmpeg_content.h"
+#include "test.h"
+
+using boost::shared_ptr;
+
+BOOST_AUTO_TEST_CASE (ffmpeg_pts_offset_test)
+{
+       shared_ptr<Film> film = new_test_film ("ffmpeg_pts_offset_test");
+       shared_ptr<FFmpegContent> content (new FFmpegContent (film, "test/data/test.mp4"));
+       content->_audio_stream.reset (new FFmpegAudioStream);
+       content->_video_frame_rate = 24;
+
+       {
+               /* Sound == video so no offset required */
+               content->_first_video = ContentTime ();
+               content->_audio_stream->first_audio = ContentTime ();
+               FFmpegDecoder decoder (content, film->log());
+               BOOST_CHECK_EQUAL (decoder._pts_offset, ContentTime ());
+       }
+
+       {
+               /* Common offset should be removed */
+               content->_first_video = ContentTime::from_seconds (600);
+               content->_audio_stream->first_audio = ContentTime::from_seconds (600);
+               FFmpegDecoder decoder (content, film->log());
+               BOOST_CHECK_EQUAL (decoder._pts_offset, ContentTime::from_seconds (-600));
+       }
+
+       {
+               /* Video is on a frame boundary */
+               content->_first_video = ContentTime::from_frames (1, 24);
+               content->_audio_stream->first_audio = ContentTime ();
+               FFmpegDecoder decoder (content, film->log());
+               BOOST_CHECK_EQUAL (decoder._pts_offset, ContentTime ());
+       }
+
+       {
+               /* Video is off a frame boundary */
+               double const frame = 1.0 / 24.0;
+               content->_first_video = ContentTime::from_seconds (frame + 0.0215);
+               content->_audio_stream->first_audio = ContentTime ();
+               FFmpegDecoder decoder (content, film->log());
+               BOOST_CHECK_CLOSE (decoder._pts_offset.seconds(), (frame - 0.0215), 0.00001);
+       }
+
+       {
+               /* Video is off a frame boundary and both have a common offset */
+               double const frame = 1.0 / 24.0;
+               content->_first_video = ContentTime::from_seconds (frame + 0.0215 + 4.1);
+               content->_audio_stream->first_audio = ContentTime::from_seconds (4.1);
+               FFmpegDecoder decoder (content, film->log());
+               BOOST_CHECK_EQUAL (decoder._pts_offset.seconds(), (frame - 0.0215) - 4.1);
+       }
+}
index 14c01a9763d32d00963bddf94b2e4b83dddd286e..888834511677c8d95f7cffa76a2c921b0dc3fff9 100644 (file)
@@ -1,5 +1,5 @@
 /*
-    Copyright (C) 2013 Carl Hetherington <cth@carlh.net>
+    Copyright (C) 2013-2014 Carl Hetherington <cth@carlh.net>
 
     This program is free software; you can redistribute it and/or modify
     it under the terms of the GNU General Public License as published by
 
 */
 
+/** @file  test/file_group_test.cc
+ *  @brief Check that FileGroup works.
+ */
+
 #include <stdint.h>
 #include <cstdio>
 #include <boost/test/unit_test.hpp>
index 1f06aa538568b6a83f57f75d36410eea47a69c3e..cc29f4472193255f0e5acc2020b5bf7df802975b 100644 (file)
@@ -1,5 +1,5 @@
 /*
-    Copyright (C) 2013 Carl Hetherington <cth@carlh.net>
+    Copyright (C) 2013-2014 Carl Hetherington <cth@carlh.net>
 
     This program is free software; you can redistribute it and/or modify
     it under the terms of the GNU General Public License as published by
 
 */
 
+/** @file  test/film_metadata_test.cc
+ *  @brief Test some basic reading/writing of film metadata.
+ */
+
 #include <sstream>
 #include <boost/test/unit_test.hpp>
 #include <boost/filesystem.hpp>
@@ -33,13 +37,9 @@ using boost::shared_ptr;
 
 BOOST_AUTO_TEST_CASE (film_metadata_test)
 {
-       string const test_film = "build/test/film_metadata_test";
-       
-       if (boost::filesystem::exists (test_film)) {
-               boost::filesystem::remove_all (test_film);
-       }
+       shared_ptr<Film> f = new_test_film ("film_metadata_test");
+       boost::filesystem::path dir = test_film_dir ("film_metadata_test");
 
-       shared_ptr<Film> f (new Film (test_film));
        f->_dci_date = boost::gregorian::from_undelimited_string ("20130211");
        BOOST_CHECK (f->container() == 0);
        BOOST_CHECK (f->dcp_content_type() == 0);
@@ -52,9 +52,9 @@ BOOST_AUTO_TEST_CASE (film_metadata_test)
 
        list<string> ignore;
        ignore.push_back ("Key");
-       check_xml ("test/data/metadata.xml.ref", test_film + "/metadata.xml", ignore);
+       check_xml ("test/data/metadata.xml.ref", dir.string() + "/metadata.xml", ignore);
 
-       shared_ptr<Film> g (new Film (test_film));
+       shared_ptr<Film> g (new Film (dir));
        g->read_metadata ();
 
        BOOST_CHECK_EQUAL (g->name(), "fred");
@@ -62,5 +62,5 @@ BOOST_AUTO_TEST_CASE (film_metadata_test)
        BOOST_CHECK_EQUAL (g->container(), Ratio::from_id ("185"));
        
        g->write_metadata ();
-       check_xml ("test/data/metadata.xml.ref", test_film + "/metadata.xml", ignore);
+       check_xml ("test/data/metadata.xml.ref", dir.string() + "/metadata.xml", ignore);
 }
index 2135b3738f50a669b39b2678a51bd404eb755a2f..e710b09341e2d53f38ef71399bd0f4236474d908 100644 (file)
@@ -1,5 +1,5 @@
 /*
-    Copyright (C) 2012 Carl Hetherington <cth@carlh.net>
+    Copyright (C) 2012-2014 Carl Hetherington <cth@carlh.net>
 
     This program is free software; you can redistribute it and/or modify
     it under the terms of the GNU General Public License as published by
 
 */
 
+/** @file  test/frame_rate_test.cc
+ *  @brief Tests for FrameRateChange and the computation of the best
+ *  frame rate for the DCP.
+ */
+
 #include <boost/test/unit_test.hpp>
 #include "lib/film.h"
 #include "lib/config.h"
@@ -26,7 +31,7 @@
 
 using boost::shared_ptr;
 
-/* Test Playlist::best_dcp_frame_rate and FrameRateConversion
+/* Test Playlist::best_dcp_frame_rate and FrameRateChange
    with a single piece of content.
 */
 BOOST_AUTO_TEST_CASE (best_dcp_frame_rate_test_single)
index f876c8f65fc08c1e9d12b5758c982a7abe93f18e..d3b0681718d43b2019008b898d2f16b04c7d6124 100644 (file)
@@ -1,5 +1,5 @@
 /*
-    Copyright (C) 2012 Carl Hetherington <cth@carlh.net>
+    Copyright (C) 2012-2014 Carl Hetherington <cth@carlh.net>
 
     This program is free software; you can redistribute it and/or modify
     it under the terms of the GNU General Public License as published by
 
 */
 
+/** @file  test/image_test.cc
+ *  @brief Tests of the Image class.
+ *
+ *  @see test/make_black_test.cc, test/pixel_formats_test.cc
+ */
+
 #include <boost/test/unit_test.hpp>
 #include <Magick++.h>
 #include "lib/image.h"
index 4d32b1e0ccf8692497f5be9778b594d2485b98d2..2022a8ddadf0ab5d464244b7b0124d6d1294f45b 100644 (file)
@@ -1,5 +1,5 @@
 /*
-    Copyright (C) 2012 Carl Hetherington <cth@carlh.net>
+    Copyright (C) 2012-2014 Carl Hetherington <cth@carlh.net>
 
     This program is free software; you can redistribute it and/or modify
     it under the terms of the GNU General Public License as published by
 
 */
 
+/** @file  test/job_test.cc
+ *  @brief Basic tests of Job and JobManager.
+ */
+
 #include <boost/test/unit_test.hpp>
 #include "lib/job.h"
 #include "lib/job_manager.h"
index 88c1bd0f46d7f60c293b7a20d911e46ea1b8aa3f..0ae2fd13713f3bb45d25fbd8c34dbf6f5e688735 100644 (file)
 
 */
 
+/** @file  test/make_black_test.cc
+ *  @brief Check that Image::make_black works, and doesn't use values which crash
+ *  sws_scale().
+ *
+ *  @see test/image_test.cc
+ */
+
 #include <boost/test/unit_test.hpp>
 #include <dcp/util.h>
 extern "C" {
@@ -27,9 +34,6 @@ extern "C" {
 
 using std::list;
 
-/* Check that Image::make_black works, and doesn't use values which crash
-   sws_scale().
-*/
 BOOST_AUTO_TEST_CASE (make_black_test)
 {
        dcp::Size in_size (512, 512);
index 1b720d9bf5d3b88fe2ecf1f2399c1c9209674bdc..8f6f1e81c4d028bbbc9286ad3039384861a54789 100644 (file)
@@ -1,5 +1,5 @@
 /*
-    Copyright (C) 2013 Carl Hetherington <cth@carlh.net>
+    Copyright (C) 2013-2014 Carl Hetherington <cth@carlh.net>
 
     This program is free software; you can redistribute it and/or modify
     it under the terms of the GNU General Public License as published by
 
 */
 
+/** @file  src/pixel_formats_test.cc
+ *  @brief Make sure that Image::lines() and Image::bytes_per_pixel() return the right
+ *  things for various pixel formats.
+ *
+ *  @see test/image_test.cc
+ */
+
 #include <boost/test/unit_test.hpp>
 #include <list>
 extern "C" {
index ced0bd61a0dd5c981e4499e32feed994f008e3ca..fa8a9b6e6ce4eb5093b1592c8cc2147231df9e60 100644 (file)
 
 */
 
+/* @file  test/player_silence_padding_test.cc
+ * @brief Check that the Player correctly generates silence when used with a silent FFmpegContent.
+ */
+
 #include <iostream>
 #include <boost/test/unit_test.hpp>
 #include "lib/film.h"
@@ -30,7 +34,6 @@
 using std::cout;
 using boost::shared_ptr;
 
-/* Check that the Player correctly generates silence when used with a silent FFmpegContent */
 BOOST_AUTO_TEST_CASE (player_silence_padding_test)
 {
        shared_ptr<Film> film = new_test_film ("player_silence_padding_test");
index f3784cad292d4ac5b2076d00e0a2174ae8075107..f5ac3ca64bff3f2b39bc939233b1c29c7aabafe9 100644 (file)
@@ -1,5 +1,5 @@
 /*
-    Copyright (C) 2012 Carl Hetherington <cth@carlh.net>
+    Copyright (C) 2012-2014 Carl Hetherington <cth@carlh.net>
 
     This program is free software; you can redistribute it and/or modify
     it under the terms of the GNU General Public License as published by
 
 */
 
+/** @file  test/ratio_test.cc
+ *  @brief Test Ratio and fit_ratio_within().
+ */
+
 #include <iostream>
 #include <boost/test/unit_test.hpp>
 #include <dcp/util.h>
index acb4acaf8c58c73c87aa2b4f6c7a9240b58b28be..dfbc9f60d9537e9baba3369e99a9aa1a074df45f 100644 (file)
 
 */
 
+/** @file  test/recover_test.cc
+ *  @brief Test recovery of a DCP transcode after a crash.
+ */
+
 #include <boost/test/unit_test.hpp>
 #include <dcp/stereo_picture_mxf.h>
 #include "lib/film.h"
@@ -35,7 +39,6 @@ note (dcp::NoteType, string n)
        cout << n << "\n";
 }
 
-/** Test recovery of a DCP transcode after a crash */
 BOOST_AUTO_TEST_CASE (recover_test)
 {
        shared_ptr<Film> film = new_test_film ("recover_test");
index 6cedf91795e8d7196d6f2b8b365fc7e7a4a5aa91..4f66420ea4bedbeafd58439ca5d5f5d5987d453c 100644 (file)
@@ -1,5 +1,5 @@
 /*
-    Copyright (C) 2013 Carl Hetherington <cth@carlh.net>
+    Copyright (C) 2013-2014 Carl Hetherington <cth@carlh.net>
 
     This program is free software; you can redistribute it and/or modify
     it under the terms of the GNU General Public License as published by
 
 */
 
+/** @file  test/repeat_frame_test.cc
+ *  @brief Test the repeat of frames by the player when putting a 24fps
+ *  source into a 48fps DCP.
+ *
+ *  @see test/skip_frame_test.cc
+ */
+
 #include <boost/test/unit_test.hpp>
 #include "test.h"
 #include "lib/film.h"
@@ -26,9 +33,6 @@
 
 using boost::shared_ptr;
 
-/* Test the repeat of frames by the player when putting a 24fps
-   source into a 48fps DCP.
-*/
 BOOST_AUTO_TEST_CASE (repeat_frame_test)
 {
        shared_ptr<Film> film = new_test_film ("repeat_frame_test");
index 3be251b3a75129c0daa83f8182ab19f7df51dc42..ffd636ac8ffb6371503d6f1a90743fd945f55c0a 100644 (file)
@@ -1,5 +1,5 @@
 /*
-    Copyright (C) 2013 Carl Hetherington <cth@carlh.net>
+    Copyright (C) 2013-2014 Carl Hetherington <cth@carlh.net>
 
     This program is free software; you can redistribute it and/or modify
     it under the terms of the GNU General Public License as published by
 
 */
 
+/** @file  test/resampler_test.cc
+ *  @brief Check that the timings that come back from the resampler correspond
+ *  to the number of samples it generates.
+ */
+
 #include <boost/test/unit_test.hpp>
 #include "lib/audio_buffers.h"
 #include "lib/resampler.h"
@@ -44,9 +49,6 @@ resampler_test_one (int from, int to)
        }
 }      
                
-/** Check that the timings that come back from the resampler correspond
-    to the number of samples it generates.
-*/
 BOOST_AUTO_TEST_CASE (resampler_test)
 {
        resampler_test_one (44100, 48000);
index bf8da8aac59ce4288e5ec1c7cb43b3e11779eab0..704c2c7dab65086829bb19e271879cd40cd8e313 100644 (file)
@@ -1,5 +1,5 @@
 /*
-    Copyright (C) 2013 Carl Hetherington <cth@carlh.net>
+    Copyright (C) 2013-2014 Carl Hetherington <cth@carlh.net>
 
     This program is free software; you can redistribute it and/or modify
     it under the terms of the GNU General Public License as published by
 
 */
 
+/** @file test/scaling_test.cc
+ *  @brief Test scaling and black-padding of images from a still-image source.
+ */
+
 #include <boost/test/unit_test.hpp>
 #include "lib/image_content.h"
 #include "lib/ratio.h"
 #include "lib/dcp_content_type.h"
 #include "test.h"
 
-/** @file test/scaling_test.cc
- *  @brief Test scaling and black-padding of images from a still-image source.
- */
-
 using std::string;
 using boost::shared_ptr;
 
index e4472ad4fef042f52f4822e56f5b82b2290a2009..ff369062662b6807fe45a56e57d5d4631c033d48 100644 (file)
@@ -1,5 +1,5 @@
 /*
-    Copyright (C) 2013 Carl Hetherington <cth@carlh.net>
+    Copyright (C) 2013-2014 Carl Hetherington <cth@carlh.net>
 
     This program is free software; you can redistribute it and/or modify
     it under the terms of the GNU General Public License as published by
 
 */
 
+/** @file  test/silence_padding_test.cc
+ *  @brief Test the padding (with silence) of a mono source to a 6-channel DCP.
+ */
+
 #include <boost/test/unit_test.hpp>
 #include <dcp/cpl.h>
 #include <dcp/dcp.h>
@@ -34,7 +38,8 @@ using std::string;
 using boost::lexical_cast;
 using boost::shared_ptr;
 
-static void test_silence_padding (int channels)
+static void
+test_silence_padding (int channels)
 {
        string const film_name = "silence_padding_test_" + lexical_cast<string> (channels);
        shared_ptr<Film> film = new_test_film (film_name);
index 61176a7c62a2dc34a0ffb02f1342a2b23b620619..a77d8459bb317252ae1bba9295c8824f6d87e298 100644 (file)
@@ -1,5 +1,5 @@
 /*
-    Copyright (C) 2013 Carl Hetherington <cth@carlh.net>
+    Copyright (C) 2013-2014 Carl Hetherington <cth@carlh.net>
 
     This program is free software; you can redistribute it and/or modify
     it under the terms of the GNU General Public License as published by
 
 */
 
+/** @file  test/skip_frame_test.cc
+ *  @brief Test the skip of frames by the player when putting a 48fps
+ *  source into a 24fps DCP.
+ *
+ *  @see test/repeat_frame_test.cc
+ */
+
 #include <boost/test/unit_test.hpp>
 #include "test.h"
 #include "lib/film.h"
@@ -26,9 +33,6 @@
 
 using boost::shared_ptr;
 
-/* Test the skip of frames by the player when putting a 48fps
-   source into a 24fps DCP.
-*/
 BOOST_AUTO_TEST_CASE (skip_frame_test)
 {
        shared_ptr<Film> film = new_test_film ("skip_frame_test");
index 1cd7e4a4270f60144ebd706cc15468c9193710e6..f30bc64d8329964912e04307cb90ab5f96b3a3bc 100644 (file)
@@ -1,5 +1,5 @@
 /*
-    Copyright (C) 2013 Carl Hetherington <cth@carlh.net>
+    Copyright (C) 2013-2014 Carl Hetherington <cth@carlh.net>
 
     This program is free software; you can redistribute it and/or modify
     it under the terms of the GNU General Public License as published by
 
 */
 
+/** @test  test/stream_test.cc
+ *  @brief Some simple tests of FFmpegAudioStream.
+ */
+
 #include <boost/test/unit_test.hpp>
 #include <libxml++/libxml++.h>
 #include <libcxml/cxml.h>
index f38ffb59bb2375e22ef56c99346f5d10932a05f4..48bb265d515a5865b82bcfa5b28b125e589d8a61 100644 (file)
 
 */
 
+/** @file  test/subrip_test.cc
+ *  @brief Various tests of the subrip code.
+ */
+
 #include <boost/test/unit_test.hpp>
 #include <dcp/subtitle_content.h>
 #include "lib/subrip.h"
index 3f044acf1fc97ffa7cde203e7127bea7b5c1aa0f..7bbf4f7493f78359770a59286bb7e285c6845caf 100644 (file)
 
 */
 
+/** @file  test/test.cc
+ *  @brief Overall test stuff and useful methods for tests.
+ */
+
 #include <vector>
 #include <list>
 #include <Magick++.h>
index 8da9b46a891fa8daeed4cd406eb784d23b8c7cc6..5ad78103fb98d05c40cdf4e2477c29556cc17757 100644 (file)
@@ -1,5 +1,5 @@
 /*
-    Copyright (C) 2013 Carl Hetherington <cth@carlh.net>
+    Copyright (C) 2013-2014 Carl Hetherington <cth@carlh.net>
 
     This program is free software; you can redistribute it and/or modify
     it under the terms of the GNU General Public License as published by
 
 */
 
+/** @file  test/threed_test.cc
+ *  @brief Create a 3D DCP (without comparing the result to anything).
+ */
+
 #include <boost/test/unit_test.hpp>
 #include "test.h"
 #include "lib/film.h"
index b2085afe19ad4eee81c330fccd354276445203ed..5eb3e27f185a70039edf090f39ee19160b131650 100644 (file)
 
 */
 
+/** @file  test/util_test.cc
+ *  @brief Test various utility methods.
+ */
+
 #include <boost/test/unit_test.hpp>
 #include "lib/util.h"
 #include "lib/exceptions.h"
index ca53122b5f5a587103ecdce609e8e9861672e0e4..5e728af0b0402cbef0836a7c285a641cbd8d2540 100644 (file)
@@ -27,7 +27,7 @@ def build(bld):
                  ffmpeg_decoder_seek_test.cc
                  ffmpeg_decoder_sequential_test.cc
                  ffmpeg_examiner_test.cc
-                 ffmpeg_pts_offset.cc
+                 ffmpeg_pts_offset_test.cc
                  file_group_test.cc
                  film_metadata_test.cc
                  frame_rate_test.cc