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

Side by Side Diff: components/sync/api/model_type_service_unittest.cc

Issue 2130453004: [Sync] Move //sync to //components/sync. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase. Created 4 years, 4 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
« no previous file with comments | « components/sync/api/model_type_service.cc ('k') | components/sync/api/model_type_store.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 <memory> 5 #include <memory>
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/memory/ptr_util.h" 8 #include "base/memory/ptr_util.h"
9 #include "sync/api/fake_model_type_change_processor.h" 9 #include "components/sync/api/fake_model_type_change_processor.h"
10 #include "sync/api/fake_model_type_service.h" 10 #include "components/sync/api/fake_model_type_service.h"
11 #include "sync/internal_api/public/test/data_type_error_handler_mock.h" 11 #include "components/sync/core/test/data_type_error_handler_mock.h"
12 #include "testing/gtest/include/gtest/gtest.h" 12 #include "testing/gtest/include/gtest/gtest.h"
13 13
14 namespace syncer_v2 { 14 namespace syncer_v2 {
15 15
16 // A mock MTCP that lets us know when DisableSync is called. 16 // A mock MTCP that lets us know when DisableSync is called.
17 class MockModelTypeChangeProcessor : public FakeModelTypeChangeProcessor { 17 class MockModelTypeChangeProcessor : public FakeModelTypeChangeProcessor {
18 public: 18 public:
19 explicit MockModelTypeChangeProcessor(const base::Closure& disabled_callback) 19 explicit MockModelTypeChangeProcessor(const base::Closure& disabled_callback)
20 : disabled_callback_(disabled_callback) {} 20 : disabled_callback_(disabled_callback) {}
21 ~MockModelTypeChangeProcessor() override {} 21 ~MockModelTypeChangeProcessor() override {}
(...skipping 125 matching lines...) Expand 10 before | Expand all | Expand 10 after
147 service()->ResolveConflict(local_data, remote_data).type()); 147 service()->ResolveConflict(local_data, remote_data).type());
148 148
149 local_data.specifics.clear_preference(); 149 local_data.specifics.clear_preference();
150 EXPECT_TRUE(local_data.is_deleted()); 150 EXPECT_TRUE(local_data.is_deleted());
151 EXPECT_FALSE(remote_data.is_deleted()); 151 EXPECT_FALSE(remote_data.is_deleted());
152 EXPECT_EQ(ConflictResolution::USE_REMOTE, 152 EXPECT_EQ(ConflictResolution::USE_REMOTE,
153 service()->ResolveConflict(local_data, remote_data).type()); 153 service()->ResolveConflict(local_data, remote_data).type());
154 } 154 }
155 155
156 } // namespace syncer_v2 156 } // namespace syncer_v2
OLDNEW
« no previous file with comments | « components/sync/api/model_type_service.cc ('k') | components/sync/api/model_type_store.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698