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

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

Issue 1931843002: Ship Web Push subscription restrictions (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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_service_unittest.cc
diff --git a/chrome/browser/push_messaging/push_messaging_service_unittest.cc b/chrome/browser/push_messaging/push_messaging_service_unittest.cc
index a60b9859e84666a78b583d19d1d6dd4ddc7af9e5..a1139418a4e14506aad31249cc58cc5391a393d2 100644
--- a/chrome/browser/push_messaging/push_messaging_service_unittest.cc
+++ b/chrome/browser/push_messaging/push_messaging_service_unittest.cc
@@ -243,3 +243,12 @@ TEST_F(PushMessagingServiceTest, NormalizeSenderInfo) {
EXPECT_EQ(p256dh, push_service->NormalizeSenderInfo(p256dh));
}
+
+TEST_F(PushMessagingServiceTest, DifferentEndpoints) {
+ PushMessagingServiceImpl* push_service = profile()->GetPushMessagingService();
+ ASSERT_TRUE(push_service);
+
+ // Verifies that the service returns different endpoints depending on whether
+ // support for the standard protocol is requested.
+ EXPECT_NE(push_service->GetEndpoint(true), push_service->GetEndpoint(false));
+}

Powered by Google App Engine
This is Rietveld 408576698