-
Notifications
You must be signed in to change notification settings - Fork 15.4k
[clang-tidy][NFC] Add checks to tests that have no checks specified. #170895
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
@rupprecht Can you take a look? |
|
@llvm/pr-subscribers-clang-tools-extra Author: None (google-yfyang) Changes#157306 removes some default checks and this breaks a few tests where no checks were explicitly specified. Full diff: https://github.com/llvm/llvm-project/pull/170895.diff 2 Files Affected:
diff --git a/clang-tools-extra/test/clang-tidy/infrastructure/empty-database.cpp b/clang-tools-extra/test/clang-tidy/infrastructure/empty-database.cpp
index c4c504c95d475..0331dccd2ce82 100644
--- a/clang-tools-extra/test/clang-tidy/infrastructure/empty-database.cpp
+++ b/clang-tools-extra/test/clang-tidy/infrastructure/empty-database.cpp
@@ -1,5 +1,5 @@
// UNSUPPORTED: system-windows
-// RUN: clang-tidy -p %S/Inputs/empty-database %s 2>&1 | FileCheck %s
+// RUN: clang-tidy -checks='-*,clang-analyzer-*' -p %S/Inputs/empty-database %s 2>&1 | FileCheck %s
// CHECK: 'directory' field of compilation database is empty; using the current working directory instead.
diff --git a/clang-tools-extra/test/clang-tidy/infrastructure/invalid-database.cpp b/clang-tools-extra/test/clang-tidy/infrastructure/invalid-database.cpp
index 7935385c1a35a..ea9e1029706e2 100644
--- a/clang-tools-extra/test/clang-tidy/infrastructure/invalid-database.cpp
+++ b/clang-tools-extra/test/clang-tidy/infrastructure/invalid-database.cpp
@@ -1,5 +1,5 @@
// UNSUPPORTED: system-windows
-// RUN: not --crash clang-tidy -p %S/Inputs/invalid-database %s 2>&1 | FileCheck %s
+// RUN: not --crash clang-tidy -checks='-*,clang-analyzer-*' -p %S/Inputs/invalid-database %s 2>&1 | FileCheck %s
// CHECK: LLVM ERROR: Cannot chdir into "/invalid/"!
|
|
@llvm/pr-subscribers-clang-tidy Author: None (google-yfyang) Changes#157306 removes some default checks and this breaks a few tests where no checks were explicitly specified. Full diff: https://github.com/llvm/llvm-project/pull/170895.diff 2 Files Affected:
diff --git a/clang-tools-extra/test/clang-tidy/infrastructure/empty-database.cpp b/clang-tools-extra/test/clang-tidy/infrastructure/empty-database.cpp
index c4c504c95d475..0331dccd2ce82 100644
--- a/clang-tools-extra/test/clang-tidy/infrastructure/empty-database.cpp
+++ b/clang-tools-extra/test/clang-tidy/infrastructure/empty-database.cpp
@@ -1,5 +1,5 @@
// UNSUPPORTED: system-windows
-// RUN: clang-tidy -p %S/Inputs/empty-database %s 2>&1 | FileCheck %s
+// RUN: clang-tidy -checks='-*,clang-analyzer-*' -p %S/Inputs/empty-database %s 2>&1 | FileCheck %s
// CHECK: 'directory' field of compilation database is empty; using the current working directory instead.
diff --git a/clang-tools-extra/test/clang-tidy/infrastructure/invalid-database.cpp b/clang-tools-extra/test/clang-tidy/infrastructure/invalid-database.cpp
index 7935385c1a35a..ea9e1029706e2 100644
--- a/clang-tools-extra/test/clang-tidy/infrastructure/invalid-database.cpp
+++ b/clang-tools-extra/test/clang-tidy/infrastructure/invalid-database.cpp
@@ -1,5 +1,5 @@
// UNSUPPORTED: system-windows
-// RUN: not --crash clang-tidy -p %S/Inputs/invalid-database %s 2>&1 | FileCheck %s
+// RUN: not --crash clang-tidy -checks='-*,clang-analyzer-*' -p %S/Inputs/invalid-database %s 2>&1 | FileCheck %s
// CHECK: LLVM ERROR: Cannot chdir into "/invalid/"!
|
|
I'm surprised it didn't break precommit CI, do you have any buildbots that flag this? |
I am not familiar with the precommit CI to know why this isn't triggered. Perhaps these tests are disabled somehow? They fail downstream here in checks at Google. |
#157306 removes some default checks and this breaks a few tests where no checks were explicitly specified.