From de29719af2c7d1772e14b45f8da75626735246e6 Mon Sep 17 00:00:00 2001 From: Richard Date: Thu, 3 Mar 2022 17:18:08 -0700 Subject: [PATCH] [clang-tools-extra] Document clang tidy unit tests target Differential Revision: https://reviews.llvm.org/D121019 --- clang-tools-extra/docs/clang-tidy/Contributing.rst | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/clang-tools-extra/docs/clang-tidy/Contributing.rst b/clang-tools-extra/docs/clang-tidy/Contributing.rst index b177157..5849353 100644 --- a/clang-tools-extra/docs/clang-tidy/Contributing.rst +++ b/clang-tools-extra/docs/clang-tidy/Contributing.rst @@ -364,6 +364,11 @@ other support classes by writing a unit test than by writing a ``FileCheck`` int test. The ``ASTMatchersTests`` target contains unit tests for the public AST matcher classes and is a good source of testing idioms for matchers. +You can build the Clang-tidy unit tests by building the ``ClangTidyTests`` target. +Test targets in LLVM and Clang are excluded from the "build all" style action of +IDE-based CMake generators, so you need to explicitly build the target for the unit +tests to be built. + Making your check robust ^^^^^^^^^^^^^^^^^^^^^^^^ -- 2.7.4