mirror of
https://github.com/catchorg/Catch2.git
synced 2024-11-22 21:36:11 +01:00
ed7eaf2df3
Each of the two reporter bases now has its own header file, and cpp file. Even though this adds another TU to the compilation, the total CPU time taken by compilation is reduced by about 1% for debug build and ~0.5% for optimized build of the main library. (The improvement would be roughly doubles without splitting the TUs, but the maintainability hit is not worth it.) The code size of the static library build has also somewhat decreased. Follow up: Introduce combined TU for reporters, and further split apart the catch_reporter_streaming_base.hpp header into its constituent parts, as it still contains a whole bunch of other stuff.
27 lines
798 B
C++
27 lines
798 B
C++
/*
|
|
* Distributed under the Boost Software License, Version 1.0. (See accompanying
|
|
* file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
|
*/
|
|
|
|
#include <catch2/catch_tag_alias_autoregistrar.hpp>
|
|
|
|
// Some example tag aliases
|
|
CATCH_REGISTER_TAG_ALIAS( "[@nhf]", "[failing]~[.]" )
|
|
CATCH_REGISTER_TAG_ALIAS( "[@tricky]", "[tricky]~[.]" )
|
|
|
|
#ifdef __clang__
|
|
# pragma clang diagnostic ignored "-Wpadded"
|
|
# pragma clang diagnostic ignored "-Wweak-vtables"
|
|
# pragma clang diagnostic ignored "-Wc++98-compat"
|
|
#endif
|
|
|
|
#include <catch2/reporters/catch_reporter_streaming_base.hpp>
|
|
|
|
struct TestListener : Catch::TestEventListenerBase {
|
|
using TestEventListenerBase::TestEventListenerBase;
|
|
};
|
|
|
|
#include <catch2/catch_reporter_registrars.hpp>
|
|
|
|
CATCH_REGISTER_LISTENER( TestListener )
|