Keep the Added Test Includes Below the NOMINMAX Guard

test_marchingsquares.cpp and test_texture_displacement.cpp had includes inside #ifndef NOMINMAX, which the tests inherit as defined on Windows from libslic3r, so those were skipped there. .clang-tidy also ignores the MSVC STL and UCRT internals, Boost.Multiprecision's fwd.hpp and CPython's Windows include directory, as in #16068.
This commit is contained in:
Hanif Koh
2026-10-02 21:42:47 +08:00
parent 7fa7469355
commit 40f703df0c
3 changed files with 12 additions and 4 deletions
+8 -2
View File
@@ -7,8 +7,10 @@ CheckOptions:
misc-include-cleaner.UnusedIncludes: false
# Headers that declare a symbol but are not the one to include: per-platform
# implementations of wxWidgets and Boost.Thread (a Linux run would suggest the
# GTK or pthread one), library internals and forward declarations, CPython's
# headers behind Python.h, curl's behind curl.h, oneTBB's behind tbb/, and
# GTK or pthread one), library internals and forward declarations (MSVC's STL
# __msvc_* and the Windows UCRT's corecrt_* included), CPython's headers behind
# Python.h (python3.x/ on Linux and macOS, libpython/include/ on Windows),
# curl's behind curl.h, oneTBB's behind tbb/, and
# admesh's stl.h, which the include path also exposes without its directory.
# Clipper's own clipper.hpp is only included through libslic3r/clipper.hpp or
# clipper_z.hpp, which configure it first, and Boost.Polygon's headers only
@@ -27,7 +29,11 @@ CheckOptions:
.*[/\\]impl[/\\].*;
.*_fwd\.hpp;
python3\.[0-9]+[/\\].*;
libpython[/\\]include[/\\].*;
bits[/\\].*;
corecrt_.*\.h;
__msvc_.*\.hpp;
boost[/\\]multiprecision[/\\]fwd\.hpp;
imconfig\.h;
expat_external\.h;
admesh[/\\]stl\.h;
+2 -1
View File
@@ -1,5 +1,7 @@
#ifndef NOMINMAX
#define NOMINMAX
#endif
#include "libslic3r/Point.hpp"
#include <cstddef>
#include "libslic3r/libslic3r.h"
@@ -21,7 +23,6 @@
#include "libslic3r/TriangleMesh.hpp"
#include <cstdlib>
#include <catch2/benchmark/catch_benchmark.hpp>
#endif
#include <catch2/catch_all.hpp>
#include "test_utils.hpp"
@@ -1,5 +1,7 @@
#ifndef NOMINMAX
#define NOMINMAX
#endif
#include <catch2/matchers/catch_matchers_floating_point.hpp>
#include <memory>
#include <vector>
@@ -22,7 +24,6 @@
#include <Eigen/Geometry>
#include "libslic3r/libslic3r.h"
#include <catch2/catch_message.hpp>
#endif
#include <catch2/catch_all.hpp>
#include <algorithm>