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

Unified Diff: chrome/browser/ui/content_settings/content_setting_bubble_model_unittest.cc

Issue 27635002: Content settings for <audio> and <video>. Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Test fix. Created 6 years, 6 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/ui/content_settings/content_setting_bubble_model_unittest.cc
diff --git a/chrome/browser/ui/content_settings/content_setting_bubble_model_unittest.cc b/chrome/browser/ui/content_settings/content_setting_bubble_model_unittest.cc
index eb9624d9443325d1a1c8ea026689b7a8f04cb96a..cce428b942c73b8c1885749b244dabe9751a76ac 100644
--- a/chrome/browser/ui/content_settings/content_setting_bubble_model_unittest.cc
+++ b/chrome/browser/ui/content_settings/content_setting_bubble_model_unittest.cc
@@ -71,6 +71,24 @@ TEST_F(ContentSettingBubbleModelTest, ImageRadios) {
EXPECT_FALSE(bubble_content.manage_link.empty());
}
+TEST_F(ContentSettingBubbleModelTest, MediaRadios) {
+ TabSpecificContentSettings* content_settings =
+ TabSpecificContentSettings::FromWebContents(web_contents());
+ content_settings->OnContentBlocked(CONTENT_SETTINGS_TYPE_MEDIA);
+
+ scoped_ptr<ContentSettingBubbleModel> content_setting_bubble_model(
+ ContentSettingBubbleModel::CreateContentSettingBubbleModel(
+ NULL, web_contents(), profile(),
+ CONTENT_SETTINGS_TYPE_MEDIA));
+ const ContentSettingBubbleModel::BubbleContent& bubble_content =
+ content_setting_bubble_model->bubble_content();
+ EXPECT_FALSE(bubble_content.title.empty());
+ EXPECT_EQ(2U, bubble_content.radio_group.radio_items.size());
+ EXPECT_EQ(0, bubble_content.radio_group.default_item);
+ EXPECT_TRUE(bubble_content.custom_link.empty());
+ EXPECT_FALSE(bubble_content.manage_link.empty());
+}
+
TEST_F(ContentSettingBubbleModelTest, Cookies) {
TabSpecificContentSettings* content_settings =
TabSpecificContentSettings::FromWebContents(web_contents());

Powered by Google App Engine
This is Rietveld 408576698