commit | 89a46cc7866f202d7a24097b335779f227d178c0 | [log] [tgz] |
---|---|---|
author | Manojkiran Eda <manojkiran.eda@gmail.com> | Sat Aug 22 17:08:11 2020 +0530 |
committer | ManojKiran Eda <manojkiran.eda@gmail.com> | Tue Aug 25 14:36:46 2020 +0000 |
tree | bfc2a563f3637207e1ddc724617d81d5810ce26a | |
parent | 01ced284a3f1a139220c21898b05c4c933369420 [diff] |
cppcheck : Add googletest library while running cppcheck - cppcheck shows a syntaxerror while parsing TEST & TEST_F macros in the repo's test files, as cppcheck cannot understand how a TEST or a TEST_F works. Example: When repo specific CI is run on phosphor-networkd, it throws following errors: test/test_ethernet_interface.cpp:108:1: error: syntax error [syntaxError] TEST_F(TestEthernetInterface, NoIPaddress) ^ test/test_neighbor.cpp:35:1: error: syntax error [syntaxError] TEST(ParseNeighbor, SmallMsg) ^ - This commit would load googletest.cfg that contains information about google test types and functions. With such information Cppcheck understands the code better and therefore get better results. TestedBy: - Had run docker CI against the networkd, and the above mentioned errors are gone. Signed-off-by: Manojkiran Eda <manojkiran.eda@gmail.com> Change-Id: If72edd4e734fb201e8a2a937fdfe8bc62dfb5f4b
Build script for CI jobs in Jenkins.