Horizon
Loading...
Searching...
No Matches
Catch::Generators::GeneratorTracker Struct Reference
Inheritance diagram for Catch::Generators::GeneratorTracker:
Catch::TestCaseTracking::TrackerBase Catch::IGeneratorTracker Catch::TestCaseTracking::ITracker

Public Member Functions

 GeneratorTracker (TestCaseTracking::NameAndLocation const &nameAndLocation, TrackerContext &ctx, ITracker *parent)
bool isGeneratorTracker () const override
 Returns true if the instance is a generator tracker.
auto hasGenerator () const -> bool override
void close () override
auto getGenerator () const -> GeneratorBasePtr const &override
void setGenerator (GeneratorBasePtr &&generator) override
Public Member Functions inherited from Catch::TestCaseTracking::TrackerBase
 TrackerBase (NameAndLocation const &nameAndLocation, TrackerContext &ctx, ITracker *parent)
bool isComplete () const override
 Returns true if tracker run to completion (successfully or not).
void open ()
void close () override
void fail () override
Public Member Functions inherited from Catch::TestCaseTracking::ITracker
 ITracker (NameAndLocation const &nameAndLoc, ITracker *parent)
NameAndLocation const & nameAndLocation () const
ITracker * parent () const
bool isSuccessfullyCompleted () const
 Returns true if tracker run to completion succesfully.
bool isOpen () const
 Returns true if tracker has started but hasn't been completed.
bool hasStarted () const
 Returns true iff tracker has started.
void markAsNeedingAnotherRun ()
void addChild (ITrackerPtr &&child)
 Register a nested ITracker.
ITrackerfindChild (NameAndLocation const &nameAndLocation)
 Returns ptr to specific child if register with this tracker.
bool hasChildren () const
 Have any children been added?
void openChild ()
 Marks tracker as executing a child, doing se recursively up the tree.
virtual bool isSectionTracker () const
 Returns true if the instance is a section tracker.
Public Member Functions inherited from Catch::IGeneratorTracker
virtual auto getGenerator () const -> Generators::GeneratorBasePtr const &=0

Static Public Member Functions

static GeneratorTracker & acquire (TrackerContext &ctx, TestCaseTracking::NameAndLocation const &nameAndLocation)

Public Attributes

GeneratorBasePtr m_generator

Additional Inherited Members

Protected Types inherited from Catch::TestCaseTracking::ITracker
enum  CycleState {
  NotStarted , Executing , ExecutingChildren , NeedsAnotherRun ,
  CompletedSuccessfully , Failed
}
Protected Attributes inherited from Catch::TestCaseTracking::TrackerBase
TrackerContextm_ctx
Protected Attributes inherited from Catch::TestCaseTracking::ITracker
ITracker * m_parent = nullptr
Children m_children
CycleState m_runState = NotStarted

Member Function Documentation

◆ close()

void Catch::Generators::GeneratorTracker::close ( )
inlineoverridevirtual

◆ hasGenerator()

auto Catch::Generators::GeneratorTracker::hasGenerator ( ) const->bool
inlineoverridevirtual

◆ isGeneratorTracker()

bool Catch::Generators::GeneratorTracker::isGeneratorTracker ( ) const
inlineoverridevirtual

Returns true if the instance is a generator tracker.

Subclasses should override to true if they are, replaces RTTI for internal debug checks.

Reimplemented from Catch::TestCaseTracking::ITracker.

◆ setGenerator()

void Catch::Generators::GeneratorTracker::setGenerator ( GeneratorBasePtr && generator)
inlineoverridevirtual

The documentation for this struct was generated from the following file: