OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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/basictypes.h" | 5 #include "base/basictypes.h" |
6 #include "base/command_line.h" | 6 #include "base/command_line.h" |
7 #include "chrome/browser/sync/profile_sync_service.h" | 7 #include "chrome/browser/sync/profile_sync_service.h" |
8 #include "chrome/browser/sync/test/integration/apps_helper.h" | 8 #include "chrome/browser/sync/test/integration/apps_helper.h" |
9 #include "chrome/browser/sync/test/integration/sync_app_list_helper.h" | 9 #include "chrome/browser/sync/test/integration/sync_app_list_helper.h" |
10 #include "chrome/browser/sync/test/integration/sync_integration_test_util.h" | 10 #include "chrome/browser/sync/test/integration/sync_integration_test_util.h" |
(...skipping 15 matching lines...) Expand all Loading... |
26 | 26 |
27 } // namespace | 27 } // namespace |
28 | 28 |
29 class SingleClientAppListSyncTest : public SyncTest { | 29 class SingleClientAppListSyncTest : public SyncTest { |
30 public: | 30 public: |
31 SingleClientAppListSyncTest() : SyncTest(SINGLE_CLIENT) {} | 31 SingleClientAppListSyncTest() : SyncTest(SINGLE_CLIENT) {} |
32 | 32 |
33 virtual ~SingleClientAppListSyncTest() {} | 33 virtual ~SingleClientAppListSyncTest() {} |
34 | 34 |
35 // SyncTest | 35 // SyncTest |
36 virtual void SetUpCommandLine(CommandLine* command_line) OVERRIDE { | 36 virtual void SetUpCommandLine(CommandLine* command_line) override { |
37 SyncTest::SetUpCommandLine(command_line); | 37 SyncTest::SetUpCommandLine(command_line); |
38 command_line->AppendSwitch(app_list::switches::kEnableSyncAppList); | 38 command_line->AppendSwitch(app_list::switches::kEnableSyncAppList); |
39 } | 39 } |
40 | 40 |
41 virtual bool SetupClients() OVERRIDE { | 41 virtual bool SetupClients() override { |
42 if (!SyncTest::SetupClients()) | 42 if (!SyncTest::SetupClients()) |
43 return false; | 43 return false; |
44 | 44 |
45 // Init SyncAppListHelper to ensure that the extension system is initialized | 45 // Init SyncAppListHelper to ensure that the extension system is initialized |
46 // for each Profile. | 46 // for each Profile. |
47 SyncAppListHelper::GetInstance(); | 47 SyncAppListHelper::GetInstance(); |
48 return true; | 48 return true; |
49 } | 49 } |
50 | 50 |
51 private: | 51 private: |
(...skipping 16 matching lines...) Expand all Loading... |
68 } | 68 } |
69 | 69 |
70 app_list::AppListSyncableService* service = | 70 app_list::AppListSyncableService* service = |
71 app_list::AppListSyncableServiceFactory::GetForProfile(verifier()); | 71 app_list::AppListSyncableServiceFactory::GetForProfile(verifier()); |
72 ASSERT_EQ(kNumApps + kNumDefaultApps, service->GetNumSyncItemsForTest()); | 72 ASSERT_EQ(kNumApps + kNumDefaultApps, service->GetNumSyncItemsForTest()); |
73 | 73 |
74 ASSERT_TRUE(AwaitCommitActivityCompletion(GetSyncService((0)))); | 74 ASSERT_TRUE(AwaitCommitActivityCompletion(GetSyncService((0)))); |
75 ASSERT_TRUE(AllProfilesHaveSameAppListAsVerifier()); | 75 ASSERT_TRUE(AllProfilesHaveSameAppListAsVerifier()); |
76 | 76 |
77 } | 77 } |
OLD | NEW |