mirror of
https://github.com/catchorg/Catch2.git
synced 2024-11-26 15:26:11 +01:00
TrackerContext: Remove misleading instance static method.
TrackerContext is not used as singleton, so just remove this misleading method
This commit is contained in:
parent
91b617c462
commit
4a1ca1ab55
@ -32,11 +32,6 @@ namespace TestCaseTracking {
|
|||||||
ITracker::~ITracker() = default;
|
ITracker::~ITracker() = default;
|
||||||
|
|
||||||
|
|
||||||
TrackerContext& TrackerContext::instance() {
|
|
||||||
static TrackerContext s_instance;
|
|
||||||
return s_instance;
|
|
||||||
}
|
|
||||||
|
|
||||||
ITracker& TrackerContext::startRun() {
|
ITracker& TrackerContext::startRun() {
|
||||||
m_rootTracker = std::make_shared<SectionTracker>( NameAndLocation( "{root}", CATCH_INTERNAL_LINEINFO ), *this, nullptr );
|
m_rootTracker = std::make_shared<SectionTracker>( NameAndLocation( "{root}", CATCH_INTERNAL_LINEINFO ), *this, nullptr );
|
||||||
m_currentTracker = nullptr;
|
m_currentTracker = nullptr;
|
||||||
|
@ -71,8 +71,6 @@ namespace TestCaseTracking {
|
|||||||
|
|
||||||
public:
|
public:
|
||||||
|
|
||||||
static TrackerContext& instance();
|
|
||||||
|
|
||||||
ITracker& startRun();
|
ITracker& startRun();
|
||||||
void endRun();
|
void endRun();
|
||||||
|
|
||||||
|
@ -8,21 +8,6 @@
|
|||||||
#include "internal/catch_suppress_warnings.h"
|
#include "internal/catch_suppress_warnings.h"
|
||||||
#include "internal/catch_test_case_tracker.h"
|
#include "internal/catch_test_case_tracker.h"
|
||||||
|
|
||||||
|
|
||||||
namespace Catch
|
|
||||||
{
|
|
||||||
class LocalContext {
|
|
||||||
|
|
||||||
public:
|
|
||||||
TrackerContext& operator()() const {
|
|
||||||
return TrackerContext::instance();
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
} // namespace Catch
|
|
||||||
|
|
||||||
// -------------------
|
|
||||||
|
|
||||||
#include "catch.hpp"
|
#include "catch.hpp"
|
||||||
|
|
||||||
using namespace Catch;
|
using namespace Catch;
|
||||||
|
Loading…
Reference in New Issue
Block a user