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

Unified Diff: chrome/browser/push_messaging/push_messaging_browsertest.cc

Issue 1133083002: Reject the permissionState promise with NotSupported Exception (2/3) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix failing test Created 5 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/push_messaging/push_messaging_browsertest.cc
diff --git a/chrome/browser/push_messaging/push_messaging_browsertest.cc b/chrome/browser/push_messaging/push_messaging_browsertest.cc
index fe531d2b46a5b5867e32fd59e9094af50e6cc804..7b7dc711097305c36c0b69cca280dc740c8a4322 100644
--- a/chrome/browser/push_messaging/push_messaging_browsertest.cc
+++ b/chrome/browser/push_messaging/push_messaging_browsertest.cc
@@ -370,8 +370,13 @@ IN_PROC_BROWSER_TEST_F(PushMessagingManifestUserVisibleOnlyTrueTest,
ASSERT_TRUE(RunScript("subscribePush()", &script_result));
EXPECT_EQ(GetEndpointForSubscriptionId("1-0"), script_result);
+ // permissionState has been introduced later so it does not
+ // respect the manifest key.
ASSERT_TRUE(RunScript("permissionState()", &script_result));
- EXPECT_EQ("permission status - granted", script_result);
+ EXPECT_EQ(
+ "NotSupportedError - Push subscriptions that don't enable"
+ " userVisibleOnly are not supported.",
+ script_result);
}
IN_PROC_BROWSER_TEST_F(PushMessagingBrowserTest, SubscribePersisted) {

Powered by Google App Engine
This is Rietveld 408576698