diff options
Diffstat (limited to 'src/catch2/catch_session.cpp')
-rw-r--r-- | src/catch2/catch_session.cpp | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/src/catch2/catch_session.cpp b/src/catch2/catch_session.cpp index 128f21d9..f1ed5f9c 100644 --- a/src/catch2/catch_session.cpp +++ b/src/catch2/catch_session.cpp @@ -13,13 +13,13 @@ #include <catch2/internal/catch_run_context.hpp> #include <catch2/catch_test_spec.hpp> #include <catch2/catch_version.hpp> -#include <catch2/interfaces/catch_interfaces_reporter.hpp> #include <catch2/internal/catch_startup_exception_registry.hpp> #include <catch2/internal/catch_sharding.hpp> +#include <catch2/internal/catch_test_case_registry_impl.hpp> #include <catch2/internal/catch_textflow.hpp> #include <catch2/internal/catch_windows_h_proxy.hpp> #include <catch2/reporters/catch_reporter_multi.hpp> -#include <catch2/interfaces/catch_interfaces_reporter_registry.hpp> +#include <catch2/internal/catch_reporter_registry.hpp> #include <catch2/interfaces/catch_interfaces_reporter_factory.hpp> #include <catch2/internal/catch_move_and_forward.hpp> #include <catch2/internal/catch_stdstreams.hpp> @@ -27,6 +27,7 @@ #include <algorithm> #include <cassert> +#include <exception> #include <iomanip> #include <set> @@ -341,6 +342,12 @@ namespace Catch { return 2; } + if ( totals.testCases.total() > 0 && + totals.testCases.total() == totals.testCases.skipped + && !m_config->zeroTestsCountAsSuccess() ) { + return 4; + } + // Note that on unices only the lower 8 bits are usually used, clamping // the return value to 255 prevents false negative when some multiple // of 256 tests has failed |