Menu

clang-tidy and test for pull requests

2020-11-23
2020-11-23
  • Abhijit Sawant

    Abhijit Sawant - 2020-11-23

    Hello,

    I have a question about process one needs to follow while submitting code change related to code formatting and running tests. While setting up development environment using cmake I noticed cppcheck uses clang-tidy and ctest. Do one need to run clang-tidy and ctest before creating pull request?

    One more related question. When I run clang-tidy using configuration /cppcheck/.clang-tidy I get too many warnings. I had to add following checks to ignore list to bring warning down to manageable level

    -llvmlibc-*,-misc-no-recursion,-misc-unused-parameters*

    I am curious how others are handling this?

     

    Last edit: Abhijit Sawant 2020-11-23
  • Daniel Marjamäki

    Do one need to run clang-tidy and ctest before creating pull request?

    no this is not necessary. I never use ctest/clang-tidy locally myself. feel free to do it if you want.

    I think running the unit tests locally is a good thing. But CI has lots of various tests and you can't run all that.. it would be pretty impractical.

    When I run clang-tidy using configuration /cppcheck/.clang-tidy I get too many warnings

    ok .. I have not used that myself.

     

Log in to post a comment.