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

Side by Side Diff: google_apis/gcm/engine/gservices_settings_unittest.cc

Issue 1137463003: Support getting and deleting token for Instance ID. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Add new files 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 unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "base/strings/string_number_conversions.h" 5 #include "base/strings/string_number_conversions.h"
6 #include "google_apis/gcm/engine/gservices_settings.h" 6 #include "google_apis/gcm/engine/gservices_settings.h"
7 #include "google_apis/gcm/engine/registration_info.h"
8 #include "testing/gtest/include/gtest/gtest.h" 7 #include "testing/gtest/include/gtest/gtest.h"
9 8
10 namespace gcm { 9 namespace gcm {
11 10
12 namespace { 11 namespace {
13 12
14 const int64 kAlternativeCheckinInterval = 16 * 60 * 60; 13 const int64 kAlternativeCheckinInterval = 16 * 60 * 60;
15 const char kAlternativeCheckinURL[] = "http://alternative.url/checkin"; 14 const char kAlternativeCheckinURL[] = "http://alternative.url/checkin";
16 const char kAlternativeMCSHostname[] = "alternative.gcm.host"; 15 const char kAlternativeMCSHostname[] = "alternative.gcm.host";
17 const int kAlternativeMCSSecurePort = 7777; 16 const int kAlternativeMCSSecurePort = 7777;
(...skipping 309 matching lines...) Expand 10 before | Expand all | Expand 10 after
327 checkin_response.Clear(); 326 checkin_response.Clear();
328 AddSettingsToResponse(checkin_response, settings_diff, true); 327 AddSettingsToResponse(checkin_response, settings_diff, true);
329 EXPECT_TRUE(settings().UpdateFromCheckinResponse(checkin_response)); 328 EXPECT_TRUE(settings().UpdateFromCheckinResponse(checkin_response));
330 EXPECT_EQ(full_settings, settings().settings_map()); 329 EXPECT_EQ(full_settings, settings().settings_map());
331 // Default setting back to norm. 330 // Default setting back to norm.
332 EXPECT_EQ(GURL("https://mtalk.google.com:5228"), 331 EXPECT_EQ(GURL("https://mtalk.google.com:5228"),
333 settings().GetMCSMainEndpoint()); 332 settings().GetMCSMainEndpoint());
334 } 333 }
335 334
336 } // namespace gcm 335 } // namespace gcm
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698