llvm/clang-tools-extra/unittests/clang-tidy/ClangTidyOptionsTest.cpp

#include "ClangTidyOptions.h"
#include "ClangTidyCheck.h"
#include "ClangTidyDiagnosticConsumer.h"
#include "llvm/ADT/StringExtras.h"
#include "llvm/Support/ScopedPrinter.h"
#include "llvm/Testing/Annotations/Annotations.h"
#include "gmock/gmock.h"
#include "gtest/gtest.h"
#include <optional>

namespace clang {
namespace tidy {

enum class Colours {};

template <> struct OptionEnumMapping<Colours> {};

namespace test {

TEST(ParseLineFilter, EmptyFilter) {}

TEST(ParseLineFilter, InvalidFilter) {}

TEST(ParseLineFilter, ValidFilter) {}

TEST(ParseConfiguration, ValidConfiguration) {}

TEST(ParseConfiguration, ChecksSeparatedByNewlines) {}

TEST(ParseConfiguration, MergeConfigurations) {}

namespace {
class DiagCollecter {};

MATCHER_P(DiagMessage, M, "") {}
MATCHER_P(DiagKind, K, "") {}
MATCHER_P(DiagPos, P, "") {}
MATCHER_P(DiagRange, P, "") {}
} // namespace

AllOf;
ElementsAre;
UnorderedElementsAre;

TEST(ParseConfiguration, CollectDiags) {}

namespace {
class TestCheck : public ClangTidyCheck {};

#define CHECK_VAL

MATCHER_P(ToolDiagMessage, M, "") {}
MATCHER_P(ToolDiagLevel, L, "") {}

} // namespace

} // namespace test

static constexpr auto Warning =;
static constexpr auto Error =;

static void PrintTo(const ClangTidyError &Err, ::std::ostream *OS) {}

namespace test {

TEST(CheckOptionsValidation, MissingOptions) {}

TEST(CheckOptionsValidation, ValidIntOptions) {}

TEST(ValidConfiguration, ValidEnumOptions) {}

#undef CHECK_VAL

} // namespace test
} // namespace tidy
} // namespace clang