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

Side by Side Diff: components/sync/driver/backend_migrator_unittest.cc

Issue 2407163004: [Sync] Move some directory-related things from core/ to syncable/. (Closed)
Patch Set: Created 4 years, 2 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/driver/backend_migrator.cc ('k') | components/sync/driver/change_processor.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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "components/sync/driver/backend_migrator.h" 5 #include "components/sync/driver/backend_migrator.h"
6 6
7 #include <memory> 7 #include <memory>
8 8
9 #include "base/message_loop/message_loop.h" 9 #include "base/message_loop/message_loop.h"
10 #include "base/run_loop.h" 10 #include "base/run_loop.h"
11 #include "base/tracked_objects.h" 11 #include "base/tracked_objects.h"
12 #include "components/sync/base/model_type_test_util.h" 12 #include "components/sync/base/model_type_test_util.h"
13 #include "components/sync/core/test/test_user_share.h"
14 #include "components/sync/core/write_transaction.h"
15 #include "components/sync/driver/data_type_manager_mock.h" 13 #include "components/sync/driver/data_type_manager_mock.h"
16 #include "components/sync/driver/fake_sync_service.h" 14 #include "components/sync/driver/fake_sync_service.h"
17 #include "components/sync/protocol/sync.pb.h" 15 #include "components/sync/protocol/sync.pb.h"
18 #include "components/sync/syncable/directory.h" 16 #include "components/sync/syncable/directory.h"
17 #include "components/sync/syncable/test_user_share.h"
18 #include "components/sync/syncable/write_transaction.h"
19 #include "testing/gmock/include/gmock/gmock.h" 19 #include "testing/gmock/include/gmock/gmock.h"
20 #include "testing/gtest/include/gtest/gtest.h" 20 #include "testing/gtest/include/gtest/gtest.h"
21 21
22 using ::testing::_; 22 using ::testing::_;
23 using ::testing::Eq; 23 using ::testing::Eq;
24 using ::testing::Mock; 24 using ::testing::Mock;
25 using ::testing::NiceMock; 25 using ::testing::NiceMock;
26 using ::testing::Return; 26 using ::testing::Return;
27 27
28 namespace syncer { 28 namespace syncer {
(...skipping 268 matching lines...) Expand 10 before | Expand all | Expand 10 after
297 .WillOnce(Return(DataTypeManager::CONFIGURED)); 297 .WillOnce(Return(DataTypeManager::CONFIGURED));
298 EXPECT_CALL(*manager(), PurgeForMigration(_, CONFIGURE_REASON_MIGRATION)) 298 EXPECT_CALL(*manager(), PurgeForMigration(_, CONFIGURE_REASON_MIGRATION))
299 .Times(1); 299 .Times(1);
300 migrator()->MigrateTypes(to_migrate); 300 migrator()->MigrateTypes(to_migrate);
301 SetUnsyncedTypes(ModelTypeSet()); 301 SetUnsyncedTypes(ModelTypeSet());
302 SendConfigureDone(DataTypeManager::ABORTED, ModelTypeSet()); 302 SendConfigureDone(DataTypeManager::ABORTED, ModelTypeSet());
303 EXPECT_EQ(BackendMigrator::IDLE, migrator()->state()); 303 EXPECT_EQ(BackendMigrator::IDLE, migrator()->state());
304 } 304 }
305 305
306 }; // namespace syncer 306 }; // namespace syncer
OLDNEW
« no previous file with comments | « components/sync/driver/backend_migrator.cc ('k') | components/sync/driver/change_processor.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698