OTest2
A C++ testing framework
Public Member Functions | List of all members
OTest2::ObjectScenario Class Referenceabstract

Inteface of a testing object scheduled by the scenario (test, suite and test case) More...

#include <objectscenario.h>

Inheritance diagram for OTest2::ObjectScenario:
Inheritance graph
[legend]
Collaboration diagram for OTest2::ObjectScenario:
Collaboration graph
[legend]

Public Member Functions

 ObjectScenario ()
 Dtor. More...
 
virtual ~ObjectScenario ()
 Dtor. More...
 
 ObjectScenario (const ObjectScenario &)=delete
 
ObjectScenariooperator= (const ObjectScenario &)=delete
 
virtual bool startUpObject (const Context &context_, int index_)=0
 Execute start-up function at specified index. More...
 
virtual void scheduleBody (const Context &context_, ScenarioPtr scenario_, ObjectPtr me_)=0
 Schedule body of the testing object. More...
 
virtual void tearDownObject (const Context &context_, int index_)=0
 Execute tear-down function at specified index. More...
 
- Public Member Functions inherited from OTest2::Object
 Object (const Object &)=delete
 
Objectoperator= (const Object &)=delete
 
 Object ()
 Ctor. More...
 
virtual ~Object ()
 Dtor. More...
 
virtual std::string getName () const =0
 Get object's name. More...
 

Detailed Description

Inteface of a testing object scheduled by the scenario (test, suite and test case)

Definition at line 37 of file objectscenario.h.

Constructor & Destructor Documentation

◆ ObjectScenario() [1/2]

OTest2::ObjectScenario::ObjectScenario ( )

Dtor.

Definition at line 23 of file objectscenario.cpp.

◆ ~ObjectScenario()

OTest2::ObjectScenario::~ObjectScenario ( )
virtual

Dtor.

Definition at line 27 of file objectscenario.cpp.

◆ ObjectScenario() [2/2]

OTest2::ObjectScenario::ObjectScenario ( const ObjectScenario )
delete

Member Function Documentation

◆ operator=()

ObjectScenario& OTest2::ObjectScenario::operator= ( const ObjectScenario )
delete

◆ scheduleBody()

virtual void OTest2::ObjectScenario::scheduleBody ( const Context context_,
ScenarioPtr  scenario_,
ObjectPtr  me_ 
)
pure virtual

Schedule body of the testing object.

Parameters
context_The OTest2 context
scenario_The scenario representing this object
me_A shared pointer pointing this instance

Implemented in OTest2::SuiteGenerated, OTest2::CaseGenerated, and OTest2::TestRoot.

◆ startUpObject()

virtual bool OTest2::ObjectScenario::startUpObject ( const Context context_,
int  index_ 
)
pure virtual

Execute start-up function at specified index.

Parameters
context_The OTest2 context
index_The zero based index of the start-up function
Returns
True if the start-up function exists and has been run

Implemented in OTest2::CaseGenerated, OTest2::SuiteGenerated, and OTest2::TestRoot.

◆ tearDownObject()

virtual void OTest2::ObjectScenario::tearDownObject ( const Context context_,
int  index_ 
)
pure virtual

Execute tear-down function at specified index.

Parameters
context_The OTest2 context
index_The zero based index of the tear-down function

Implemented in OTest2::CaseGenerated, OTest2::SuiteGenerated, and OTest2::TestRoot.


The documentation for this class was generated from the following files: