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

Unified Diff: chrome/browser/media/webrtc/media_stream_device_permission_context_unittest.cc

Issue 2886363002: Flip the kRequireSecureOriginsForPepperMediaRequests to enabled by default (Closed)
Patch Set: Flip the kRequireSecureOriginsForPepperMediaRequests to enabled by default 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/media/webrtc/media_stream_device_permission_context_unittest.cc
diff --git a/chrome/browser/media/webrtc/media_stream_device_permission_context_unittest.cc b/chrome/browser/media/webrtc/media_stream_device_permission_context_unittest.cc
index be3d3ea775c12c0c1fd12ddaa3ffb521b0d9ea43..5c8682cf5818ddf82a17fca5be5c0f4e77da83b5 100644
--- a/chrome/browser/media/webrtc/media_stream_device_permission_context_unittest.cc
+++ b/chrome/browser/media/webrtc/media_stream_device_permission_context_unittest.cc
@@ -67,21 +67,23 @@ class MediaStreamDevicePermissionContextTests
secure_url.GetOrigin(),
content_settings_type, std::string()));
- EXPECT_EQ(CONTENT_SETTING_ASK,
- permission_context
- .GetPermissionStatus(nullptr /* render_frame_host */,
- insecure_url, insecure_url)
- .content_setting);
-
- EXPECT_EQ(CONTENT_SETTING_ASK,
- permission_context
- .GetPermissionStatus(nullptr /* render_frame_host */,
- insecure_url, secure_url)
- .content_setting);
-
- base::test::ScopedFeatureList scoped_feature_list;
- scoped_feature_list.InitAndEnableFeature(
- features::kRequireSecureOriginsForPepperMediaRequests);
+ {
+ // TODO(raymes): Remove this when crbug.com/526324 is fixed.
+ base::test::ScopedFeatureList scoped_feature_list;
+ scoped_feature_list.InitAndDisableFeature(
+ features::kRequireSecureOriginsForPepperMediaRequests);
+ EXPECT_EQ(CONTENT_SETTING_ASK,
+ permission_context
+ .GetPermissionStatus(nullptr /* render_frame_host */,
+ insecure_url, insecure_url)
+ .content_setting);
+
+ EXPECT_EQ(CONTENT_SETTING_ASK,
+ permission_context
+ .GetPermissionStatus(nullptr /* render_frame_host */,
+ insecure_url, secure_url)
+ .content_setting);
+ }
EXPECT_EQ(CONTENT_SETTING_BLOCK,
permission_context
@@ -108,15 +110,18 @@ class MediaStreamDevicePermissionContextTests
content_settings_type,
std::string()));
- EXPECT_EQ(CONTENT_SETTING_ASK,
- permission_context
- .GetPermissionStatus(nullptr /* render_frame_host */,
- secure_url, secure_url)
- .content_setting);
+ {
+ // TODO(raymes): Remove this when crbug.com/526324 is fixed.
+ base::test::ScopedFeatureList scoped_feature_list;
+ scoped_feature_list.InitAndDisableFeature(
+ features::kRequireSecureOriginsForPepperMediaRequests);
+ EXPECT_EQ(CONTENT_SETTING_ASK,
+ permission_context
+ .GetPermissionStatus(nullptr /* render_frame_host */,
+ secure_url, secure_url)
+ .content_setting);
+ }
- base::test::ScopedFeatureList scoped_feature_list;
- scoped_feature_list.InitAndEnableFeature(
- features::kRequireSecureOriginsForPepperMediaRequests);
EXPECT_EQ(CONTENT_SETTING_ASK,
permission_context
.GetPermissionStatus(nullptr /* render_frame_host */,

Powered by Google App Engine
This is Rietveld 408576698