mirror of
https://github.com/catchorg/Catch2.git
synced 2024-11-22 05:16:10 +01:00
Split ITestInvoker into its own header
This commit is contained in:
parent
c487b27d9d
commit
1f881ab464
@ -218,6 +218,7 @@ set(INTERFACE_HEADERS
|
||||
${SOURCES_DIR}/interfaces/catch_interfaces_reporter.hpp
|
||||
${SOURCES_DIR}/interfaces/catch_interfaces_reporter_factory.hpp
|
||||
${SOURCES_DIR}/interfaces/catch_interfaces_tag_alias_registry.hpp
|
||||
${SOURCES_DIR}/interfaces/catch_interfaces_test_invoker.hpp
|
||||
${SOURCES_DIR}/interfaces/catch_interfaces_testcase.hpp
|
||||
)
|
||||
set(INTERFACE_SOURCES
|
||||
|
@ -13,6 +13,7 @@
|
||||
#include <catch2/internal/catch_run_context.hpp>
|
||||
#include <catch2/catch_test_spec.hpp>
|
||||
#include <catch2/catch_version.hpp>
|
||||
#include <catch2/interfaces/catch_interfaces_testcase.hpp>
|
||||
#include <catch2/interfaces/catch_interfaces_reporter.hpp>
|
||||
#include <catch2/internal/catch_startup_exception_registry.hpp>
|
||||
#include <catch2/internal/catch_sharding.hpp>
|
||||
|
@ -6,6 +6,7 @@
|
||||
|
||||
// SPDX-License-Identifier: BSL-1.0
|
||||
#include <catch2/catch_test_spec.hpp>
|
||||
#include <catch2/interfaces/catch_interfaces_testcase.hpp>
|
||||
#include <catch2/internal/catch_reusable_string_stream.hpp>
|
||||
#include <catch2/internal/catch_string_manip.hpp>
|
||||
#include <catch2/catch_test_case_info.hpp>
|
||||
|
@ -31,6 +31,7 @@
|
||||
#include <catch2/interfaces/catch_interfaces_reporter.hpp>
|
||||
#include <catch2/interfaces/catch_interfaces_reporter_factory.hpp>
|
||||
#include <catch2/interfaces/catch_interfaces_tag_alias_registry.hpp>
|
||||
#include <catch2/interfaces/catch_interfaces_test_invoker.hpp>
|
||||
#include <catch2/interfaces/catch_interfaces_testcase.hpp>
|
||||
|
||||
#endif // CATCH_INTERFACES_ALL_HPP_INCLUDED
|
||||
|
21
src/catch2/interfaces/catch_interfaces_test_invoker.hpp
Normal file
21
src/catch2/interfaces/catch_interfaces_test_invoker.hpp
Normal file
@ -0,0 +1,21 @@
|
||||
|
||||
// Copyright Catch2 Authors
|
||||
// Distributed under the Boost Software License, Version 1.0.
|
||||
// (See accompanying file LICENSE.txt or copy at
|
||||
// https://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// SPDX-License-Identifier: BSL-1.0
|
||||
#ifndef CATCH_INTERFACES_TEST_INVOKER_HPP_INCLUDED
|
||||
#define CATCH_INTERFACES_TEST_INVOKER_HPP_INCLUDED
|
||||
|
||||
namespace Catch {
|
||||
|
||||
class ITestInvoker {
|
||||
public:
|
||||
virtual void invoke() const = 0;
|
||||
virtual ~ITestInvoker(); // = default
|
||||
};
|
||||
|
||||
} // namespace Catch
|
||||
|
||||
#endif // CATCH_INTERFACES_TEST_INVOKER_HPP_INCLUDED
|
@ -9,6 +9,5 @@
|
||||
#include <catch2/interfaces/catch_interfaces_testcase.hpp>
|
||||
|
||||
namespace Catch {
|
||||
ITestInvoker::~ITestInvoker() = default;
|
||||
ITestCaseRegistry::~ITestCaseRegistry() = default;
|
||||
}
|
||||
|
@ -14,13 +14,6 @@ namespace Catch {
|
||||
|
||||
class TestSpec;
|
||||
struct TestCaseInfo;
|
||||
|
||||
class ITestInvoker {
|
||||
public:
|
||||
virtual void invoke () const = 0;
|
||||
virtual ~ITestInvoker(); // = default
|
||||
};
|
||||
|
||||
class TestCaseHandle;
|
||||
class IConfig;
|
||||
|
||||
|
@ -16,8 +16,9 @@
|
||||
|
||||
namespace Catch {
|
||||
|
||||
class TestCaseHandle;
|
||||
class IConfig;
|
||||
class ITestInvoker;
|
||||
class TestCaseHandle;
|
||||
class TestSpec;
|
||||
|
||||
std::vector<TestCaseHandle> sortTests( IConfig const& config, std::vector<TestCaseHandle> const& unsortedTestCases );
|
||||
|
@ -16,6 +16,7 @@
|
||||
#include <iterator>
|
||||
|
||||
namespace Catch {
|
||||
ITestInvoker::~ITestInvoker() = default;
|
||||
|
||||
namespace {
|
||||
static StringRef extractClassName( StringRef classOrMethodName ) {
|
||||
|
@ -10,7 +10,7 @@
|
||||
|
||||
#include <catch2/internal/catch_source_line_info.hpp>
|
||||
#include <catch2/internal/catch_noncopyable.hpp>
|
||||
#include <catch2/interfaces/catch_interfaces_testcase.hpp>
|
||||
#include <catch2/interfaces/catch_interfaces_test_invoker.hpp>
|
||||
#include <catch2/internal/catch_stringref.hpp>
|
||||
#include <catch2/internal/catch_unique_ptr.hpp>
|
||||
#include <catch2/internal/catch_unique_name.hpp>
|
||||
|
@ -65,6 +65,7 @@ internal_headers = [
|
||||
'interfaces/catch_interfaces_reporter.hpp',
|
||||
'interfaces/catch_interfaces_reporter_factory.hpp',
|
||||
'interfaces/catch_interfaces_tag_alias_registry.hpp',
|
||||
'interfaces/catch_interfaces_test_invoker.hpp',
|
||||
'interfaces/catch_interfaces_testcase.hpp',
|
||||
'internal/catch_assertion_handler.hpp',
|
||||
'internal/catch_case_insensitive_comparisons.hpp',
|
||||
|
Loading…
Reference in New Issue
Block a user