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

Side by Side Diff: content/browser/media/encrypted_media_browsertest.cc

Issue 2845973005: Reland of name kDisableGestureRequirementForMediaPlayback and make it a test-only flag. (Closed)
Patch Set: Created 3 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved.
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/command_line.h" 5 #include "base/command_line.h"
6 #include "base/strings/string_number_conversions.h" 6 #include "base/strings/string_number_conversions.h"
7 #include "base/strings/utf_string_conversions.h" 7 #include "base/strings/utf_string_conversions.h"
8 #include "build/build_config.h" 8 #include "build/build_config.h"
9 #include "content/browser/media/media_browsertest.h" 9 #include "content/browser/media/media_browsertest.h"
10 #include "content/public/common/content_switches.h" 10 #include "content/public/common/content_switches.h"
(...skipping 131 matching lines...) Expand 10 before | Expand all | Expand 10 after
142 142
143 protected: 143 protected:
144 // We want to fail quickly when a test fails because an error is encountered. 144 // We want to fail quickly when a test fails because an error is encountered.
145 void AddTitlesToAwait(content::TitleWatcher* title_watcher) override { 145 void AddTitlesToAwait(content::TitleWatcher* title_watcher) override {
146 MediaBrowserTest::AddTitlesToAwait(title_watcher); 146 MediaBrowserTest::AddTitlesToAwait(title_watcher);
147 title_watcher->AlsoWaitForTitle(base::ASCIIToUTF16(kEmeNotSupportedError)); 147 title_watcher->AlsoWaitForTitle(base::ASCIIToUTF16(kEmeNotSupportedError));
148 title_watcher->AlsoWaitForTitle(base::ASCIIToUTF16(kEmeKeyError)); 148 title_watcher->AlsoWaitForTitle(base::ASCIIToUTF16(kEmeKeyError));
149 } 149 }
150 150
151 void SetUpCommandLine(base::CommandLine* command_line) override { 151 void SetUpCommandLine(base::CommandLine* command_line) override {
152 command_line->AppendSwitch( 152 command_line->AppendSwitch(switches::kIgnoreAutoplayRestrictionsForTests);
153 switches::kDisableGestureRequirementForMediaPlayback);
154 #if defined(SUPPORTS_EXTERNAL_CLEAR_KEY_IN_CONTENT_SHELL) 153 #if defined(SUPPORTS_EXTERNAL_CLEAR_KEY_IN_CONTENT_SHELL)
155 command_line->AppendSwitchASCII(switches::kEnableFeatures, 154 command_line->AppendSwitchASCII(switches::kEnableFeatures,
156 media::kExternalClearKeyForTesting.name); 155 media::kExternalClearKeyForTesting.name);
157 #endif 156 #endif
158 } 157 }
159 }; 158 };
160 159
161 using ::testing::Combine; 160 using ::testing::Combine;
162 using ::testing::Values; 161 using ::testing::Values;
163 162
(...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after
261 TestFrameSizeChange(); 260 TestFrameSizeChange();
262 } 261 }
263 262
264 IN_PROC_BROWSER_TEST_F(EncryptedMediaTest, UnknownKeySystemThrowsException) { 263 IN_PROC_BROWSER_TEST_F(EncryptedMediaTest, UnknownKeySystemThrowsException) {
265 RunEncryptedMediaTest(kDefaultEmePlayer, "bear-a_enc-a.webm", 264 RunEncryptedMediaTest(kDefaultEmePlayer, "bear-a_enc-a.webm",
266 kWebMVorbisAudioOnly, "com.example.foo", SrcType::MSE, 265 kWebMVorbisAudioOnly, "com.example.foo", SrcType::MSE,
267 kEmeNotSupportedError); 266 kEmeNotSupportedError);
268 } 267 }
269 268
270 } // namespace content 269 } // namespace content
OLDNEW
« no previous file with comments | « chromecast/browser/cast_browser_main_parts.cc ('k') | content/browser/media/media_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698