Disable tidy checks in TidyGlobalNoChecks

* Save repeated strings in TidyFlags of build.ninja rules.
* Some of these checks were disabled to upgrade clang-tidy.
  They could later be moved to TidyDefaultGlobalChecks and
  TidyExternalVendorChecks if not breaking the build.
  Some projects can then enable those checks locally.

Test: WITH_TIDY=1 make; make tidy-soong_subset
Change-Id: I70e4218c929e3c88f766f2c68c56c51356110e72
This commit is contained in:
Chih-Hung Hsieh
2022-06-09 17:58:41 -07:00
parent 2d481842b1
commit 43b920e707
3 changed files with 34 additions and 20 deletions

View File

@@ -122,7 +122,7 @@ func TestTidyChecks(t *testing.T) {
firstXyzChecks := "-checks='-*','xyz-*',"
localXyzChecks := "'-*','xyz-*'"
localAbcChecks := "'-abc*','xyz-*',mycheck"
extraGlobalChecks := ",-bugprone-easily-swappable-parameters,"
extraGlobalChecks := ",${config.TidyGlobalNoChecks}"
testCases := []struct {
libNumber int // 1,2,3,...
checks []string // must have substrings in -checks