Commit 34326482 authored by skau's avatar skau Committed by Commit bot

Extend message for sync presubmit

The message containing 'notification type' from
CheckNotificationTypeMatchesProtoMessageName is confusing since the source
of the error contains many similar strings.  Remind committers to refer to
the definition of the struct for more information.

New message:
'Error at lines 127-129 in model_type.cc: In the construction of ModelTypeInfo: notification type "WIFI_CREDENTIALIEA" does not match proto message name defined in sync.proto: "wifi_credentials"'

BUG=

Review-Url: https://codereview.chromium.org/2335413002
Cr-Commit-Position: refs/heads/master@{#419263}
parent d9402500
...@@ -261,7 +261,8 @@ def CheckNotificationTypeMatchesProtoMessageName( ...@@ -261,7 +261,8 @@ def CheckNotificationTypeMatchesProtoMessageName(
if map_entry.notification_type.lower() != proto_message_name: if map_entry.notification_type.lower() != proto_message_name:
return [ return [
FormatPresubmitError( FormatPresubmitError(
output_api,'notification type "%s" does not match proto message' output_api,'In the construction of ModelTypeInfo: notification type'
' "%s" does not match proto message'
' name defined in sync.proto: ' '"%s"' % ' name defined in sync.proto: ' '"%s"' %
(map_entry.notification_type, proto_message_name), (map_entry.notification_type, proto_message_name),
map_entry.affected_lines)] map_entry.affected_lines)]
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment