Index: chrome/browser/notifications/notification_interactive_uitest_support.cc |
diff --git a/chrome/browser/notifications/notification_interactive_uitest_support.cc b/chrome/browser/notifications/notification_interactive_uitest_support.cc |
index 21467c6b3d2550fa858fd4977901bd93fdad9beb..36bd4050fd35ba64b6116bf3a75526c4e9e656b9 100644 |
--- a/chrome/browser/notifications/notification_interactive_uitest_support.cc |
+++ b/chrome/browser/notifications/notification_interactive_uitest_support.cc |
@@ -122,10 +122,10 @@ void NotificationsTest::SetUpDefaultCommandLine( |
InProcessBrowserTest::SetUpDefaultCommandLine(command_line); |
// Temporary change while the whole support class is changed to deal |
// with native notifications. crbug.com/714679 |
-#if defined(OS_MACOSX) |
+#if BUILDFLAG(ENABLE_NATIVE_NOTIFICATIONS) |
command_line->AppendSwitchASCII(switches::kDisableFeatures, |
features::kNativeNotifications.name); |
-#endif |
+#endif // BUILDFLAG(ENABLE_NATIVE_NOTIFICATIONS) |
} |
int NotificationsTest::GetNotificationCount() { |
@@ -294,16 +294,30 @@ content::WebContents* NotificationsTest::GetActiveWebContents( |
} |
void NotificationsTest::EnableFullscreenNotifications() { |
+#if BUILDFLAG(ENABLE_NATIVE_NOTIFICATIONS) |
+ feature_list_.InitWithFeatures( |
+ {features::kPreferHtmlOverPlugins, |
+ features::kAllowFullscreenWebNotificationsFeature}, |
+ {features::kNativeNotifications}); |
+#else |
feature_list_.InitWithFeatures( |
{features::kPreferHtmlOverPlugins, |
features::kAllowFullscreenWebNotificationsFeature}, |
{}); |
+#endif // BUILDFLAG(ENABLE_NATIVE_NOTIFICATIONS) |
} |
void NotificationsTest::DisableFullscreenNotifications() { |
+#if BUILDFLAG(ENABLE_NATIVE_NOTIFICATIONS) |
+ feature_list_.InitWithFeatures( |
+ {features::kPreferHtmlOverPlugins}, |
+ {features::kAllowFullscreenWebNotificationsFeature, |
+ features::kNativeNotifications}); |
+#else |
feature_list_.InitWithFeatures( |
{features::kPreferHtmlOverPlugins}, |
{features::kAllowFullscreenWebNotificationsFeature}); |
+#endif // BUILDFLAG(ENABLE_NATIVE_NOTIFICATIONS) |
} |
void NotificationsTest::DropOriginPreference(const GURL& origin) { |