MCPcopy Index your code
hub / github.com/cpplint/cpplint / TestFunctionLengthsCheck

Method TestFunctionLengthsCheck

cpplint_unittest.py:6329–6336  ·  view source on GitHub ↗

Check warnings for long function bodies are as expected. Args: code: C++ source code expected to generate a warning message. expected_message: Message expected to be generated by the C++ code.

(self, code, expected_message)

Source from the content-addressed store, hash-verified

6327 cpplint._FunctionState._TEST_TRIGGER = self.old_test_trigger
6328
6329 def TestFunctionLengthsCheck(self, code, expected_message):
6330 """Check warnings for long function bodies are as expected.
6331
6332 Args:
6333 code: C++ source code expected to generate a warning message.
6334 expected_message: Message expected to be generated by the C++ code.
6335 """
6336 assert expected_message == self.PerformFunctionLengthsCheck(code)
6337
6338 def TriggerLines(self, error_level):
6339 """Return number of lines needed to trigger a function length warning.

Calls 1

Tested by

no test coverage detected