OLD | NEW |
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 "chrome/browser/chromeos/login/profile_auth_data.h" | 5 #include "chrome/browser/chromeos/login/profile_auth_data.h" |
6 | 6 |
7 #include <string> | 7 #include <string> |
8 | 8 |
9 #include "base/bind.h" | 9 #include "base/bind.h" |
10 #include "base/bind_helpers.h" | 10 #include "base/bind_helpers.h" |
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
54 const char kChannelIDPrivateKey1[] = "private key 1"; | 54 const char kChannelIDPrivateKey1[] = "private key 1"; |
55 const char kChannelIDPrivateKey2[] = "private key 2"; | 55 const char kChannelIDPrivateKey2[] = "private key 2"; |
56 const char kChannelIDCert1[] = "cert 1"; | 56 const char kChannelIDCert1[] = "cert 1"; |
57 const char kChannelIDCert2[] = "cert 2"; | 57 const char kChannelIDCert2[] = "cert 2"; |
58 | 58 |
59 } // namespace | 59 } // namespace |
60 | 60 |
61 class ProfileAuthDataTest : public testing::Test { | 61 class ProfileAuthDataTest : public testing::Test { |
62 public: | 62 public: |
63 // testing::Test: | 63 // testing::Test: |
64 virtual void SetUp() OVERRIDE; | 64 virtual void SetUp() override; |
65 | 65 |
66 void PopulateUserBrowserContext(); | 66 void PopulateUserBrowserContext(); |
67 | 67 |
68 void Transfer( | 68 void Transfer( |
69 bool transfer_auth_cookies_and_channel_ids_on_first_login, | 69 bool transfer_auth_cookies_and_channel_ids_on_first_login, |
70 bool transfer_saml_auth_cookies_on_subsequent_login); | 70 bool transfer_saml_auth_cookies_on_subsequent_login); |
71 | 71 |
72 net::CookieList GetUserCookies(); | 72 net::CookieList GetUserCookies(); |
73 net::ChannelIDStore::ChannelIDList GetUserChannelIDs(); | 73 net::ChannelIDStore::ChannelIDList GetUserChannelIDs(); |
74 | 74 |
(...skipping 258 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
333 PopulateUserBrowserContext(); | 333 PopulateUserBrowserContext(); |
334 | 334 |
335 Transfer(false, true); | 335 Transfer(false, true); |
336 | 336 |
337 VerifyTransferredUserProxyAuthEntry(); | 337 VerifyTransferredUserProxyAuthEntry(); |
338 VerifyUserCookies(kCookieValue2, kCookieValue1); | 338 VerifyUserCookies(kCookieValue2, kCookieValue1); |
339 VerifyUserChannelID(kChannelIDPrivateKey2, kChannelIDCert2); | 339 VerifyUserChannelID(kChannelIDPrivateKey2, kChannelIDCert2); |
340 } | 340 } |
341 | 341 |
342 } // namespace chromeos | 342 } // namespace chromeos |
OLD | NEW |