diff options
author | rsimha@chromium.org <rsimha@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-07-01 23:05:42 +0000 |
---|---|---|
committer | rsimha@chromium.org <rsimha@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-07-01 23:05:42 +0000 |
commit | d9344f42fd5240fc0920905ea48d83b65b9c3965 (patch) | |
tree | 4d9eae14a1c38c18221307b28723d726bf6e36b5 /net/tools/testserver | |
parent | b9c4b6e28a0e311342387903b82a2f43f02810d5 (diff) | |
download | chromium_src-d9344f42fd5240fc0920905ea48d83b65b9c3965.zip chromium_src-d9344f42fd5240fc0920905ea48d83b65b9c3965.tar.gz chromium_src-d9344f42fd5240fc0920905ea48d83b65b9c3965.tar.bz2 |
Adding the extensions datatype to the python sync server.
The sync integration tests run against a local python sync server. The
extensions datatype was recently added to the client code, causing the
python server to require this update.
BUG=48040
TEST=sync_integration_tests
Review URL: http://codereview.chromium.org/2878017
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@51449 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'net/tools/testserver')
-rwxr-xr-x | net/tools/testserver/chromiumsync.py | 31 |
1 files changed, 21 insertions, 10 deletions
diff --git a/net/tools/testserver/chromiumsync.py b/net/tools/testserver/chromiumsync.py index 2268bbd..7801cdf 100755 --- a/net/tools/testserver/chromiumsync.py +++ b/net/tools/testserver/chromiumsync.py @@ -15,6 +15,9 @@ import threading import autofill_specifics_pb2 import bookmark_specifics_pb2 +import extension_specifics_pb2 +import nigori_specifics_pb2 +import password_specifics_pb2 import preference_specifics_pb2 import theme_specifics_pb2 import typed_url_specifics_pb2 @@ -26,24 +29,28 @@ import sync_pb2 # of a program, it is useful to have an enumeration. ALL_TYPES = ( TOP_LEVEL, # The type of the 'Google Chrome' folder. - BOOKMARK, AUTOFILL, - TYPED_URL, + BOOKMARK, + EXTENSIONS, + NIGORI, + PASSWORD, PREFERENCE, - # PASSWORD, # Disabled since there's no specifics proto. # SESSION, - THEME) = range(6) + THEME,
+ TYPED_URL) = range(9) # Given a sync type from ALL_TYPES, find the extension token corresponding # to that datatype. Note that TOP_LEVEL has no such token. SYNC_TYPE_TO_EXTENSION = { - BOOKMARK: bookmark_specifics_pb2.bookmark, AUTOFILL: autofill_specifics_pb2.autofill, - TYPED_URL: typed_url_specifics_pb2.typed_url, + BOOKMARK: bookmark_specifics_pb2.bookmark, + EXTENSIONS: extension_specifics_pb2.extension, + NIGORI: nigori_specifics_pb2.nigori, + PASSWORD: password_specifics_pb2.password, PREFERENCE: preference_specifics_pb2.preference, - # PASSWORD: password_specifics_pb2.password, # Disabled # SESSION: session_specifics_pb2.session, # Disabled THEME: theme_specifics_pb2.theme, + TYPED_URL: typed_url_specifics_pb2.typed_url, } # The parent ID used to indicate a top-level node. @@ -155,15 +162,19 @@ class SyncDataModel(object): parent_tag='google_chrome', sync_type=PREFERENCE), PermanentItem('google_chrome_autofill', name='Autofill', parent_tag='google_chrome', sync_type=AUTOFILL), - # TODO(nick): Disabled since the protocol does not support them yet. - # PermanentItem('google_chrome_passwords', name='Passwords', - # parent_tag='google_chrome', sync_type=PASSWORD), + PermanentItem('google_chrome_extensions', name='Extensions', + parent_tag='google_chrome', sync_type=EXTENSIONS), + PermanentItem('google_chrome_passwords', name='Passwords', + parent_tag='google_chrome', sync_type=PASSWORD), + # TODO(rsimha): Disabled since the protocol does not support it yet.
# PermanentItem('google_chrome_sessions', name='Sessions', # parent_tag='google_chrome', SESSION), PermanentItem('google_chrome_themes', name='Themes', parent_tag='google_chrome', sync_type=THEME), PermanentItem('google_chrome_typed_urls', name='Typed URLs', parent_tag='google_chrome', sync_type=TYPED_URL), + PermanentItem('google_chrome_nigori', name='Nigori', + parent_tag='google_chrome', sync_type=NIGORI), ] def __init__(self): |