Introduce compile time toggle to remove Matchers from TU

The toggle is `CATCH_CONFIG_DISABLE_MATCHERS` and the only use is
to speed up compilation of small TUs. For large ones it is likely
insignificant, because the speed up is constant relative to
number of tests/assertions in TU.
This commit is contained in:
Martin Hořeňovský committed 2017-07-28 21:34:34 +02:00
1 parent 35c1301bd5
commit 0ca4cfb743
11 files changed
+55 -9

No files matched your search

+2
View File
@@ -58,8 +58,10 @@ namespace Catch {
void useActiveException( ResultDisposition::Flags resultDisposition = ResultDisposition::Normal );
void captureResult( ResultWas::OfType resultType );
void captureExpression();
#if defined(CATCH_CONFIG_DISABLE_MATCHERS)
void captureExpectedException( std::string const& expectedMessage );
void captureExpectedException( Matchers::Impl::MatcherBase<std::string> const& matcher );
#endif // CATCH_CONFIG_DISABLE_MATCHERS
void handleResult( AssertionResult const& result );
void react();
bool shouldDebugBreak() const;