OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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/profiles/profile.h" | 5 #include "chrome/browser/profiles/profile.h" |
6 #include "chrome/browser/sync/test/integration/sync_arc_package_helper.h" | 6 #include "chrome/browser/sync/test/integration/sync_arc_package_helper.h" |
7 #include "chrome/browser/sync/test/integration/sync_integration_test_util.h" | |
8 #include "chrome/browser/sync/test/integration/sync_test.h" | 7 #include "chrome/browser/sync/test/integration/sync_test.h" |
| 8 #include "chrome/browser/sync/test/integration/updated_progress_marker_checker.h
" |
9 #include "chrome/browser/ui/app_list/arc/arc_package_syncable_service.h" | 9 #include "chrome/browser/ui/app_list/arc/arc_package_syncable_service.h" |
10 | 10 |
11 using sync_integration_test_util::AwaitCommitActivityCompletion; | |
12 | |
13 namespace arc { | 11 namespace arc { |
14 | 12 |
15 namespace { | 13 namespace { |
16 | 14 |
17 bool AllProfilesHaveSameArcPackageDetails() { | 15 bool AllProfilesHaveSameArcPackageDetails() { |
18 return SyncArcPackageHelper::GetInstance() | 16 return SyncArcPackageHelper::GetInstance() |
19 ->AllProfilesHaveSamePackageDetails(); | 17 ->AllProfilesHaveSamePackageDetails(); |
20 } | 18 } |
21 | 19 |
22 } // namespace | 20 } // namespace |
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
61 IN_PROC_BROWSER_TEST_F(SingleClientArcPackageSyncTest, | 59 IN_PROC_BROWSER_TEST_F(SingleClientArcPackageSyncTest, |
62 ArcPackageInstallSomePackages) { | 60 ArcPackageInstallSomePackages) { |
63 ASSERT_TRUE(SetupSync()); | 61 ASSERT_TRUE(SetupSync()); |
64 | 62 |
65 constexpr size_t kNumPackages = 5; | 63 constexpr size_t kNumPackages = 5; |
66 for (size_t i = 0; i < kNumPackages; ++i) { | 64 for (size_t i = 0; i < kNumPackages; ++i) { |
67 sync_helper()->InstallPackageWithIndex(GetProfile(0), i); | 65 sync_helper()->InstallPackageWithIndex(GetProfile(0), i); |
68 sync_helper()->InstallPackageWithIndex(verifier(), i); | 66 sync_helper()->InstallPackageWithIndex(verifier(), i); |
69 } | 67 } |
70 | 68 |
71 ASSERT_TRUE(AwaitCommitActivityCompletion(GetSyncService(0))); | 69 ASSERT_TRUE(UpdatedProgressMarkerChecker(GetSyncService(0)).Wait()); |
72 ASSERT_TRUE(AllProfilesHaveSameArcPackageDetails()); | 70 ASSERT_TRUE(AllProfilesHaveSameArcPackageDetails()); |
73 } | 71 } |
74 | 72 |
75 } // namespace arc | 73 } // namespace arc |
OLD | NEW |