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

Unified Diff: chrome/browser/notifications/platform_notification_service_interactive_uitest.cc

Issue 2888303004: Minimize the delegate dependencies for non persistent notifications. (Closed)
Patch Set: more fixes 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/notifications/platform_notification_service_interactive_uitest.cc
diff --git a/chrome/browser/notifications/platform_notification_service_interactive_uitest.cc b/chrome/browser/notifications/platform_notification_service_interactive_uitest.cc
index dae163b3b44ad133d99abe80ca53b944d4a848bf..a8cd5f2d593de8b933f042349a8e734479a7c549 100644
--- a/chrome/browser/notifications/platform_notification_service_interactive_uitest.cc
+++ b/chrome/browser/notifications/platform_notification_service_interactive_uitest.cc
@@ -68,7 +68,8 @@ class PlatformNotificationServiceBrowserTest : public InProcessBrowserTest {
~PlatformNotificationServiceBrowserTest() override {}
// InProcessBrowserTest overrides.
- void SetUpCommandLine(base::CommandLine* command_line) override;
+ void SetUpDefaultCommandLine(base::CommandLine* command_line) override;
+
void SetUp() override;
void SetUpOnMainThread() override;
void TearDown() override;
@@ -136,11 +137,19 @@ PlatformNotificationServiceBrowserTest::PlatformNotificationServiceBrowserTest()
// filesystem.
test_page_url_(std::string("/") + kTestFileName) {}
-void PlatformNotificationServiceBrowserTest::SetUpCommandLine(
+void PlatformNotificationServiceBrowserTest::SetUpDefaultCommandLine(
base::CommandLine* command_line) {
+ InProcessBrowserTest::SetUpDefaultCommandLine(command_line);
+
+ // Needed for the Reply button tests
command_line->AppendSwitch(switches::kEnableExperimentalWebPlatformFeatures);
- InProcessBrowserTest::SetUpCommandLine(command_line);
+#if BUILDFLAG(ENABLE_NATIVE_NOTIFICATIONS)
+ // Temporary change while testss are changed to deal
+ // with native notifications. crbug.com/714679
Peter Beverloo 2017/05/31 17:52:42 TODO grammar bug number in TODO attribution
Miguel Garcia 2017/06/01 17:00:53 Done.
+ command_line->AppendSwitchASCII(switches::kDisableFeatures,
+ features::kNativeNotifications.name);
+#endif // BUILDFLAG(ENABLE_NATIVE_NOTIFICATIONS)
}
void PlatformNotificationServiceBrowserTest::SetUp() {
@@ -824,8 +833,14 @@ class PlatformNotificationServiceWithoutContentImageBrowserTest
public:
// InProcessBrowserTest overrides.
void SetUpInProcessBrowserTestFixture() override {
- scoped_feature_list_.InitAndDisableFeature(
- features::kNotificationContentImage);
+#if BUILDFLAG(ENABLE_NATIVE_NOTIFICATIONS)
+ scoped_feature_list_.InitWithFeatures(
+ {},
+ {features::kNotificationContentImage, features::kNativeNotifications});
+#else
+ scoped_feature_list_.InitWithFeatures(
+ {}, {features::kNotificationContentImage});
+#endif // BUILDFLAG(ENABLE_NATIVE_NOTIFICATIONS)
InProcessBrowserTest::SetUpInProcessBrowserTestFixture();
}

Powered by Google App Engine
This is Rietveld 408576698