From 9721048a32e245aae0e8ec6799302577a5c751e4 Mon Sep 17 00:00:00 2001 From: Omar Boukli-Hacene Date: Thu, 25 Apr 2024 22:10:17 +0200 Subject: [PATCH] Move header from internal Move `catch_case_sensitive.hpp` from directory `src/catch2/internal/internal` to be directly under `src/catch2/`. Header `catch_case_sensitive.hpp` defines `enum CaseSensitive` which is part of the public API, since it is exposed by the string matcher contracts. Fixes issue caught by Clang Tidy misc-include-cleaner check. --- src/CMakeLists.txt | 2 +- src/catch2/catch_all.hpp | 2 +- src/catch2/{internal => }/catch_case_sensitive.hpp | 0 src/catch2/internal/catch_wildcard_pattern.hpp | 2 +- src/catch2/matchers/catch_matchers_string.hpp | 4 ++-- src/catch2/meson.build | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) rename src/catch2/{internal => }/catch_case_sensitive.hpp (100%) diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 28cd4e25..aeb145b2 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -48,6 +48,7 @@ set(IMPL_HEADERS ${SOURCES_DIR}/catch_approx.hpp ${SOURCES_DIR}/catch_assertion_info.hpp ${SOURCES_DIR}/catch_assertion_result.hpp + ${SOURCES_DIR}/catch_case_sensitive.hpp ${SOURCES_DIR}/catch_config.hpp ${SOURCES_DIR}/catch_get_random_seed.hpp ${SOURCES_DIR}/catch_message.hpp @@ -67,7 +68,6 @@ set(IMPL_HEADERS ${SOURCES_DIR}/catch_version_macros.hpp ${SOURCES_DIR}/internal/catch_assertion_handler.hpp ${SOURCES_DIR}/internal/catch_case_insensitive_comparisons.hpp - ${SOURCES_DIR}/internal/catch_case_sensitive.hpp ${SOURCES_DIR}/internal/catch_clara.hpp ${SOURCES_DIR}/internal/catch_commandline.hpp ${SOURCES_DIR}/internal/catch_compare_traits.hpp diff --git a/src/catch2/catch_all.hpp b/src/catch2/catch_all.hpp index f2cc8536..57159955 100644 --- a/src/catch2/catch_all.hpp +++ b/src/catch2/catch_all.hpp @@ -26,6 +26,7 @@ #include #include #include +#include #include #include #include @@ -47,7 +48,6 @@ #include #include #include -#include #include #include #include diff --git a/src/catch2/internal/catch_case_sensitive.hpp b/src/catch2/catch_case_sensitive.hpp similarity index 100% rename from src/catch2/internal/catch_case_sensitive.hpp rename to src/catch2/catch_case_sensitive.hpp diff --git a/src/catch2/internal/catch_wildcard_pattern.hpp b/src/catch2/internal/catch_wildcard_pattern.hpp index 72479ba8..4f410859 100644 --- a/src/catch2/internal/catch_wildcard_pattern.hpp +++ b/src/catch2/internal/catch_wildcard_pattern.hpp @@ -8,7 +8,7 @@ #ifndef CATCH_WILDCARD_PATTERN_HPP_INCLUDED #define CATCH_WILDCARD_PATTERN_HPP_INCLUDED -#include +#include #include diff --git a/src/catch2/matchers/catch_matchers_string.hpp b/src/catch2/matchers/catch_matchers_string.hpp index 718022e3..61a385d0 100644 --- a/src/catch2/matchers/catch_matchers_string.hpp +++ b/src/catch2/matchers/catch_matchers_string.hpp @@ -8,9 +8,9 @@ #ifndef CATCH_MATCHERS_STRING_HPP_INCLUDED #define CATCH_MATCHERS_STRING_HPP_INCLUDED -#include -#include #include +#include +#include #include diff --git a/src/catch2/meson.build b/src/catch2/meson.build index cc45e641..5b2a047d 100644 --- a/src/catch2/meson.build +++ b/src/catch2/meson.build @@ -74,7 +74,6 @@ internal_headers = [ 'interfaces/catch_interfaces_testcase.hpp', 'internal/catch_assertion_handler.hpp', 'internal/catch_case_insensitive_comparisons.hpp', - 'internal/catch_case_sensitive.hpp', 'internal/catch_clara.hpp', 'internal/catch_commandline.hpp', 'internal/catch_compare_traits.hpp', @@ -173,6 +172,7 @@ internal_headers = [ 'catch_approx.hpp', 'catch_assertion_info.hpp', 'catch_assertion_result.hpp', + 'catch_case_sensitive.hpp', 'catch_config.hpp', 'catch_get_random_seed.hpp', 'catch_message.hpp',