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

Unified Diff: chrome/browser/sync/protocol/proto_value_conversions_unittest.cc

Issue 8774011: Fix syncing of oauth_client_id value for AppNotificationSettings (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 1 month 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/sync/protocol/proto_value_conversions.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/sync/protocol/proto_value_conversions_unittest.cc
diff --git a/chrome/browser/sync/protocol/proto_value_conversions_unittest.cc b/chrome/browser/sync/protocol/proto_value_conversions_unittest.cc
index 63ada75baf1ba14c7b990e30ecc89b2d722dd5e6..2e9db4270f6d004750b2cca2be4cb62d03afc36e 100644
--- a/chrome/browser/sync/protocol/proto_value_conversions_unittest.cc
+++ b/chrome/browser/sync/protocol/proto_value_conversions_unittest.cc
@@ -91,7 +91,17 @@ TEST_F(ProtoValueConversionsTest, AppNotificationSpecificsToValue) {
}
TEST_F(ProtoValueConversionsTest, AppSettingSpecificsToValue) {
- TestSpecificsToValue(AppSettingSpecificsToValue);
+ sync_pb::AppNotificationSettings specifics;
+ specifics.set_disabled(true);
+ specifics.set_oauth_client_id("some_id_value");
+ scoped_ptr<DictionaryValue> value(AppSettingsToValue(specifics));
+ EXPECT_FALSE(value->empty());
+ bool disabled_value = false;
+ std::string oauth_client_id_value;
+ EXPECT_TRUE(value->GetBoolean("disabled", &disabled_value));
+ EXPECT_EQ(true, disabled_value);
+ EXPECT_TRUE(value->GetString("oauth_client_id", &oauth_client_id_value));
+ EXPECT_EQ("some_id_value", oauth_client_id_value);
}
TEST_F(ProtoValueConversionsTest, AppSpecificsToValue) {
« no previous file with comments | « chrome/browser/sync/protocol/proto_value_conversions.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698