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

Unified Diff: sync/protocol/proto_enum_conversions_unittest.cc

Issue 9663023: Log the sync communication that happens between client and server. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: For review. Created 8 years, 9 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 side-by-side diff with in-line comments
Download patch
Index: sync/protocol/proto_enum_conversions_unittest.cc
diff --git a/sync/protocol/proto_enum_conversions_unittest.cc b/sync/protocol/proto_enum_conversions_unittest.cc
index 2445a30cd84e937c72e7b4092ff91fd64a620eb0..6b6c25df909c552067c2f5020808a9e09b47bc5e 100644
--- a/sync/protocol/proto_enum_conversions_unittest.cc
+++ b/sync/protocol/proto_enum_conversions_unittest.cc
@@ -58,5 +58,33 @@ TEST_F(ProtoEnumConversionsTest, GetUpdatesSourceString) {
sync_pb::GetUpdatesCallerInfo::GetUpdatesSource_MAX);
}
+TEST_F(ProtoEnumConversionsTest, GetResponseTypeString) {
+ TestEnumStringFunction(
+ GetResponseTypeString,
+ sync_pb::CommitResponse::ResponseType_MIN,
+ sync_pb::CommitResponse::ResponseType_MAX);
+}
+
+TEST_F(ProtoEnumConversionsTest, GetErrorTypeString) {
+ TestEnumStringFunction(
+ GetErrorTypeString,
+ sync_pb::SyncEnums::ErrorType_MIN,
+ sync_pb::SyncEnums::MIGRATION_DONE);
+
+ // ErrorType enum is sequential only upto MIGRATION_DONE.
akalin 2012/03/17 01:55:05 upto -> up to Although for consistency it would b
lipalani1 2012/03/19 19:24:37 Done.
+ TestEnumStringFunction(
+ GetErrorTypeString,
+ sync_pb::SyncEnums::UNKNOWN,
+ sync_pb::SyncEnums::UNKNOWN);
akalin 2012/03/17 01:55:05 replace the last UNKNOWN with ErrorType_MAX
lipalani1 2012/03/19 19:24:37 Done.
+
+}
+
+TEST_F(ProtoEnumConversionsTest, GetActionString) {
+ TestEnumStringFunction(
+ GetActionString,
+ sync_pb::ClientToServerResponse::Error::Action_MIN,
+ sync_pb::ClientToServerResponse::Error::Action_MAX);
+}
+
} // namespace
} // namespace browser_sync

Powered by Google App Engine
This is Rietveld 408576698