Convert most two client sync_integration_tests to use FakeServer
commit616e058d24cb6bbd58527506d2a3b7d509a79cc4
authorpvalenzuela@chromium.org <pvalenzuela@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>
Tue, 8 Apr 2014 05:09:40 +0000 (8 05:09 +0000)
committerpvalenzuela@chromium.org <pvalenzuela@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>
Tue, 8 Apr 2014 05:09:40 +0000 (8 05:09 +0000)
treecb0f79782e97c098709bb7671f0ef504726b2a71
parent019f6bef4f3014cb34b79d298de7ab7ba82b2851
Convert most two client sync_integration_tests to use FakeServer

This CL converts most two client sync_integration_tests to use the C++
FakeServer. The excluded tests cannot be converted yet because they
require notifications/triggering that is not implemented yet. No test
cases in two_client_apps_sync_test.cc have been converted yet due to
some observed flakiness in local runs.

In order to support the existing two client tests, many fixes to
FakeServer were made. The notable changes are:
1) Synchronization is added so that multiple clients can safely
   interact with the server.
2) A record of created PermanentEntity types is saved so that these
   entities are only created once (on first client connection).
3) The Nigori entity is now able to be mutated so additional clients
   can update its specifics.
4) UniqueClientEntity items can now be mutated. This is necessary for
   dictionary sync.
5) UniqueClientEntity items can now have parent IDs. This is necessary
   for device info sync and other types.
6) DeleteChildren has been fixed so that it no longer creates
   tombstones at the same time as searching for children. It now
   creates tombstones in a separate  pass.

BUG=323265

Review URL: https://codereview.chromium.org/221363003

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@262323 0039d316-1c4b-4281-b951-d872f2087c98
15 files changed:
chrome/browser/sync/test/integration/sync_test.cc
chrome/browser/sync/test/integration/sync_test.h
chrome/browser/sync/test/integration/two_client_app_list_sync_test.cc
chrome/browser/sync/test/integration/two_client_apps_sync_test.cc
chrome/browser/sync/test/integration/two_client_bookmarks_sync_test.cc
chrome/browser/sync/test/integration/two_client_extensions_sync_test.cc
chrome/browser/sync/test/integration/two_client_passwords_sync_test.cc
chrome/browser/sync/test/integration/two_client_preferences_sync_test.cc
chrome/browser/sync/test/integration/two_client_themes_sync_test.cc
sync/test/fake_server/fake_server.cc
sync/test/fake_server/fake_server.h
sync/test/fake_server/permanent_entity.cc
sync/test/fake_server/permanent_entity.h
sync/test/fake_server/unique_client_entity.cc
sync/test/fake_server/unique_client_entity.h