Do not check include guards in PRESUBMIT for old IPC *_message_generator.h files

They use the include guards in a very specific, peculiar way

Bug: 814776
Change-Id: I5ff8b8840f88ee993b42d7792be6267d3864f583
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1728533
Reviewed-by: Daniel Cheng <[email protected]>
Commit-Queue: Kinuko Yasuda <[email protected]>
Cr-Commit-Position: refs/heads/master@{#682943}
diff --git a/PRESUBMIT_test.py b/PRESUBMIT_test.py
index 6e32dd4..2c1c545 100755
--- a/PRESUBMIT_test.py
+++ b/PRESUBMIT_test.py
@@ -968,6 +968,15 @@
           'struct SomeFileFoo;',
           '#endif  // REQUIRED_RPCNDR_H_',
         ]),
+        # Not having proper include guard in *_message_generator.h
+        # for old IPC messages is allowed.
+        MockAffectedFile('content/common/content_message_generator.h', [
+          '#undef CONTENT_COMMON_FOO_MESSAGES_H_',
+          '#include "content/common/foo_messages.h"',
+          '#ifndef CONTENT_COMMON_FOO_MESSAGES_H_',
+          '#error "Failed to include content/common/foo_messages.h"',
+          '#endif',
+        ]),
       ]
     msgs = PRESUBMIT._CheckForIncludeGuards(
         mock_input_api, mock_output_api)