| 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 "base/command_line.h" | 5 #include "base/command_line.h" |
| 6 #include "base/macros.h" | 6 #include "base/macros.h" |
| 7 #include "chrome/browser/sync/test/integration/sync_integration_test_util.h" | 7 #include "chrome/browser/sync/test/integration/sync_integration_test_util.h" |
| 8 #include "chrome/browser/sync/test/integration/sync_test.h" | 8 #include "chrome/browser/sync/test/integration/sync_test.h" |
| 9 #include "chrome/browser/sync/test/integration/wifi_credentials_helper.h" | 9 #include "chrome/browser/sync/test/integration/wifi_credentials_helper.h" |
| 10 #include "chrome/common/chrome_switches.h" | 10 #include "chrome/common/chrome_switches.h" |
| 11 #include "components/browser_sync/common/browser_sync_switches.h" |
| 11 #include "components/wifi_sync/wifi_credential.h" | 12 #include "components/wifi_sync/wifi_credential.h" |
| 12 #include "components/wifi_sync/wifi_security_class.h" | 13 #include "components/wifi_sync/wifi_security_class.h" |
| 13 | 14 |
| 14 using sync_integration_test_util::AwaitCommitActivityCompletion; | 15 using sync_integration_test_util::AwaitCommitActivityCompletion; |
| 15 using wifi_sync::WifiCredential; | 16 using wifi_sync::WifiCredential; |
| 16 | 17 |
| 17 using WifiCredentialSet = wifi_sync::WifiCredential::CredentialSet; | 18 using WifiCredentialSet = wifi_sync::WifiCredential::CredentialSet; |
| 18 | 19 |
| 19 class SingleClientWifiCredentialsSyncTest : public SyncTest { | 20 class SingleClientWifiCredentialsSyncTest : public SyncTest { |
| 20 public: | 21 public: |
| (...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 64 | 65 |
| 65 const WifiCredentialSet verifier_credentials = | 66 const WifiCredentialSet verifier_credentials = |
| 66 wifi_credentials_helper::GetWifiCredentialsForProfile(verifier()); | 67 wifi_credentials_helper::GetWifiCredentialsForProfile(verifier()); |
| 67 EXPECT_EQ(1U, verifier_credentials.size()); | 68 EXPECT_EQ(1U, verifier_credentials.size()); |
| 68 EXPECT_EQ(WifiCredential::MakeSsidBytesForTest(ssid), | 69 EXPECT_EQ(WifiCredential::MakeSsidBytesForTest(ssid), |
| 69 verifier_credentials.begin()->ssid()); | 70 verifier_credentials.begin()->ssid()); |
| 70 | 71 |
| 71 ASSERT_TRUE(AwaitCommitActivityCompletion(GetSyncService((profile_index)))); | 72 ASSERT_TRUE(AwaitCommitActivityCompletion(GetSyncService((profile_index)))); |
| 72 EXPECT_TRUE(wifi_credentials_helper::ProfileMatchesVerifier(profile_index)); | 73 EXPECT_TRUE(wifi_credentials_helper::ProfileMatchesVerifier(profile_index)); |
| 73 } | 74 } |
| OLD | NEW |