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

Side by Side Diff: chrome/browser/media_uitest.cc

Issue 3176035: Add simple playback tests for WebM and MP4 files. (Closed)
Patch Set: Created 10 years, 4 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 unified diff | Download patch
« no previous file with comments | « no previous file | chrome/test/data/media/bear.webm » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 The Chromium Authors. All rights reserved.
scherkus (not reviewing) 2010/08/24 23:50:03 copyright year
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "base/basictypes.h" 5 #include "base/basictypes.h"
6 #include "base/file_path.h" 6 #include "base/file_path.h"
7 #include "base/platform_thread.h" 7 #include "base/platform_thread.h"
8 #include "base/string_util.h" 8 #include "base/string_util.h"
9 #include "chrome/test/ui/ui_layout_test.h" 9 #include "chrome/test/ui/ui_layout_test.h"
10 #include "chrome/test/ui/ui_test.h" 10 #include "chrome/test/ui/ui_test.h"
11 #include "net/base/net_util.h" 11 #include "net/base/net_util.h"
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
49 }; 49 };
50 50
51 TEST_F(MediaTest, VideoBearTheora) { 51 TEST_F(MediaTest, VideoBearTheora) {
52 PlayVideo("bear.ogv"); 52 PlayVideo("bear.ogv");
53 } 53 }
54 54
55 TEST_F(MediaTest, VideoBearSilentTheora) { 55 TEST_F(MediaTest, VideoBearSilentTheora) {
56 PlayVideo("bear_silent.ogv"); 56 PlayVideo("bear_silent.ogv");
57 } 57 }
58 58
59 TEST_F(MediaTest, VideoBearWebm) {
60 PlayVideo("bear.webm");
61 }
62
63 TEST_F(MediaTest, VideoBearSilentWebm) {
64 PlayVideo("bear_silent.webm");
65 }
66
67 #if defined(GOOGLE_CHROME_BUILD) || defined(USE_PROPRIETARY_CODECS)
68 TEST_F(MediaTest, VideoBearMp4) {
69 PlayVideo("bear.mp4");
70 }
71
72 TEST_F(MediaTest, VideoBearSilentMp4) {
73 PlayVideo("bear_silent.mp4");
74 }
75 #endif
76
59 TEST_F(UILayoutTest, MediaUILayoutTest) { 77 TEST_F(UILayoutTest, MediaUILayoutTest) {
60 static const char* kResources[] = { 78 static const char* kResources[] = {
61 "content", 79 "content",
62 "media-file.js", 80 "media-file.js",
63 "media-fullscreen.js", 81 "media-fullscreen.js",
64 "video-paint-test.js", 82 "video-paint-test.js",
65 "video-played.js", 83 "video-played.js",
66 "video-test.js", 84 "video-test.js",
67 }; 85 };
68 86
(...skipping 10 matching lines...) Expand all
79 InitializeForLayoutTest(test_dir, media_test_dir, kNoHttpPort); 97 InitializeForLayoutTest(test_dir, media_test_dir, kNoHttpPort);
80 98
81 // Copy resources first. 99 // Copy resources first.
82 for (size_t i = 0; i < arraysize(kResources); ++i) 100 for (size_t i = 0; i < arraysize(kResources); ++i)
83 AddResourceForLayoutTest( 101 AddResourceForLayoutTest(
84 test_dir, media_test_dir.AppendASCII(kResources[i])); 102 test_dir, media_test_dir.AppendASCII(kResources[i]));
85 103
86 for (size_t i = 0; i < arraysize(kMediaTests); ++i) 104 for (size_t i = 0; i < arraysize(kMediaTests); ++i)
87 RunLayoutTest(kMediaTests[i], kNoHttpPort); 105 RunLayoutTest(kMediaTests[i], kNoHttpPort);
88 } 106 }
OLDNEW
« no previous file with comments | « no previous file | chrome/test/data/media/bear.webm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698