| Index: components/sync/test/fake_server/bookmark_entity_builder.cc
|
| diff --git a/components/sync/test/fake_server/bookmark_entity_builder.cc b/components/sync/test/fake_server/bookmark_entity_builder.cc
|
| index e9ca35395f24501d636a2552a1e9911d71f46d14..599405faa6b629a4c2f9e82a79438164e56b8168 100644
|
| --- a/components/sync/test/fake_server/bookmark_entity_builder.cc
|
| +++ b/components/sync/test/fake_server/bookmark_entity_builder.cc
|
| @@ -12,14 +12,13 @@
|
| #include "components/sync/base/hash_util.h"
|
| #include "components/sync/base/time.h"
|
| #include "components/sync/base/unique_position.h"
|
| -#include "components/sync/engine_impl/loopback_server/persistent_bookmark_entity.h"
|
| #include "components/sync/protocol/sync.pb.h"
|
| +#include "components/sync/test/fake_server/bookmark_entity.h"
|
|
|
| using std::string;
|
| using syncer::GenerateSyncableBookmarkHash;
|
| -using syncer::LoopbackServerEntity;
|
|
|
| -// A version must be passed when creating a LoopbackServerEntity, but this value
|
| +// A version must be passed when creating a FakeServerEntity, but this value
|
| // is overrideen immediately when saving the entity in FakeServer.
|
| const int64_t kUnusedVersion = 0L;
|
|
|
| @@ -45,10 +44,10 @@
|
| parent_id_ = parent_id;
|
| }
|
|
|
| -std::unique_ptr<LoopbackServerEntity> BookmarkEntityBuilder::BuildBookmark(
|
| +std::unique_ptr<FakeServerEntity> BookmarkEntityBuilder::BuildBookmark(
|
| const GURL& url) {
|
| if (!url.is_valid()) {
|
| - return base::WrapUnique<LoopbackServerEntity>(nullptr);
|
| + return base::WrapUnique<FakeServerEntity>(nullptr);
|
| }
|
|
|
| sync_pb::EntitySpecifics entity_specifics = CreateBaseEntitySpecifics();
|
| @@ -57,7 +56,7 @@
|
| return Build(entity_specifics, kIsNotFolder);
|
| }
|
|
|
| -std::unique_ptr<LoopbackServerEntity> BookmarkEntityBuilder::BuildFolder() {
|
| +std::unique_ptr<FakeServerEntity> BookmarkEntityBuilder::BuildFolder() {
|
| const bool kIsFolder = true;
|
| return Build(CreateBaseEntitySpecifics(), kIsFolder);
|
| }
|
| @@ -72,7 +71,7 @@
|
| return entity_specifics;
|
| }
|
|
|
| -std::unique_ptr<LoopbackServerEntity> BookmarkEntityBuilder::Build(
|
| +std::unique_ptr<FakeServerEntity> BookmarkEntityBuilder::Build(
|
| const sync_pb::EntitySpecifics& entity_specifics,
|
| bool is_folder) {
|
| sync_pb::UniquePosition unique_position;
|
| @@ -82,18 +81,16 @@
|
| syncer::UniquePosition::FromInt64(0, suffix).ToProto(&unique_position);
|
|
|
| if (parent_id_.empty()) {
|
| - parent_id_ =
|
| - LoopbackServerEntity::CreateId(syncer::BOOKMARKS, "bookmark_bar");
|
| + parent_id_ = FakeServerEntity::CreateId(syncer::BOOKMARKS, "bookmark_bar");
|
| }
|
|
|
| const string id =
|
| - LoopbackServerEntity::CreateId(syncer::BOOKMARKS, base::GenerateGUID());
|
| + FakeServerEntity::CreateId(syncer::BOOKMARKS, base::GenerateGUID());
|
|
|
| - return base::WrapUnique<LoopbackServerEntity>(
|
| - new syncer::PersistentBookmarkEntity(
|
| - id, kUnusedVersion, title_, originator_cache_guid_,
|
| - originator_client_item_id_, unique_position, entity_specifics,
|
| - is_folder, parent_id_, kDefaultTime, kDefaultTime));
|
| + return base::WrapUnique<FakeServerEntity>(new BookmarkEntity(
|
| + id, kUnusedVersion, title_, originator_cache_guid_,
|
| + originator_client_item_id_, unique_position, entity_specifics, is_folder,
|
| + parent_id_, kDefaultTime, kDefaultTime));
|
| }
|
|
|
| } // namespace fake_server
|
|
|