Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(933)

Unified Diff: media/base/container_names_unittest.cc

Issue 15966005: Improve container detection testing by adding additional containers (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 7 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « media/base/container_names.cc ('k') | media/test/data/bear.ac3 » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/base/container_names_unittest.cc
diff --git a/media/base/container_names_unittest.cc b/media/base/container_names_unittest.cc
index 51cc0c0cc54c8174c5f34c01194f228d37502dcd..0e66f44791b38b9bdfe444638ffe4d70d61fd90a 100644
--- a/media/base/container_names_unittest.cc
+++ b/media/base/container_names_unittest.cc
@@ -143,6 +143,81 @@ TEST(ContainerNamesTest, FileCheckMP3) {
TestFile(CONTAINER_MP3, GetTestDataFilePath("sfx.mp3"));
}
+// Test AC3 files to ensure that the container is detected properly.
+TEST(ContainerNamesTest, FileCheckAC3) {
+ TestFile(CONTAINER_AC3, GetTestDataFilePath("bear.ac3"));
+}
+
+// Test AAC files to ensure that the container is detected properly.
+TEST(ContainerNamesTest, FileCheckAAC) {
+ TestFile(CONTAINER_AAC, GetTestDataFilePath("bear.adts"));
+}
+
+// Test AIFF files to ensure that the container is detected properly.
+TEST(ContainerNamesTest, FileCheckAIFF) {
+ TestFile(CONTAINER_AIFF, GetTestDataFilePath("bear.aiff"));
+}
+
+// Test ASF files to ensure that the container is detected properly.
+TEST(ContainerNamesTest, FileCheckASF) {
+ TestFile(CONTAINER_ASF, GetTestDataFilePath("bear.asf"));
+}
+
+// Test AVI files to ensure that the container is detected properly.
+TEST(ContainerNamesTest, FileCheckAVI) {
+ TestFile(CONTAINER_AVI, GetTestDataFilePath("bear.avi"));
+}
+
+// Test EAC3 files to ensure that the container is detected properly.
+TEST(ContainerNamesTest, FileCheckEAC3) {
+ TestFile(CONTAINER_EAC3, GetTestDataFilePath("bear.eac3"));
+}
+
+// Test FLAC files to ensure that the container is detected properly.
+TEST(ContainerNamesTest, FileCheckFLAC) {
+ TestFile(CONTAINER_FLAC, GetTestDataFilePath("bear.flac"));
+}
+
+// Test FLV files to ensure that the container is detected properly.
+TEST(ContainerNamesTest, FileCheckFLV) {
+ TestFile(CONTAINER_FLV, GetTestDataFilePath("bear.flv"));
+}
+
+// Test H261 files to ensure that the container is detected properly.
+TEST(ContainerNamesTest, FileCheckH261) {
+ TestFile(CONTAINER_H261, GetTestDataFilePath("bear.h261"));
+}
+
+// Test H263 files to ensure that the container is detected properly.
+TEST(ContainerNamesTest, FileCheckH263) {
+ TestFile(CONTAINER_H263, GetTestDataFilePath("bear.h263"));
+}
+
+// Test MJPEG files to ensure that the container is detected properly.
+TEST(ContainerNamesTest, FileCheckMJPEG) {
+ TestFile(CONTAINER_MJPEG, GetTestDataFilePath("bear.mjpeg"));
+}
+
+// Test MPEG2PS files to ensure that the container is detected properly.
+TEST(ContainerNamesTest, FileCheckMPEG2PS) {
+ TestFile(CONTAINER_MPEG2PS, GetTestDataFilePath("bear.mpeg"));
+}
+
+// Test MPEG2TS files to ensure that the container is detected properly.
+TEST(ContainerNamesTest, FileCheckMPEG2TS) {
+ TestFile(CONTAINER_MPEG2TS, GetTestDataFilePath("bear.m2ts"));
+}
+
+// Test RM files to ensure that the container is detected properly.
+TEST(ContainerNamesTest, FileCheckRM) {
+ TestFile(CONTAINER_RM, GetTestDataFilePath("bear.rm"));
+}
+
+// Test SWF files to ensure that the container is detected properly.
+TEST(ContainerNamesTest, FileCheckSWF) {
+ TestFile(CONTAINER_SWF, GetTestDataFilePath("bear.swf"));
+}
+
// Try a few non containers.
TEST(ContainerNamesTest, FileCheckUNKNOWN) {
TestFile(CONTAINER_UNKNOWN, GetTestDataFilePath("ten_byte_file"));
« no previous file with comments | « media/base/container_names.cc ('k') | media/test/data/bear.ac3 » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698