Go to the documentation of this file. 1 #ifndef CPPUNIT_HELPER_TESTSUITEBUILDERCONTEXT_H
2 #define CPPUNIT_HELPER_TESTSUITEBUILDERCONTEXT_H
8 #if CPPUNIT_NEED_DLL_DECL
9 #pragma warning( push )
10 #pragma warning( disable: 4251 ) // X needs to have dll-interface to be used by clients of class Z
52 void addTest(
Test *test );
58 std::string getFixtureName()
const;
68 std::string getTestNameFor(
const std::string &testMethodName )
const;
80 std::string
getTestNameFor(
const std::string &testMethodName,
const T& value )
const
82 return m_namer.getTestNameFor(testMethodName, value);
89 void addProperty(
const std::string &key,
90 const std::string &value );
95 const std::string getStringProperty(
const std::string &key )
const;
103 typedef std::pair<std::string,std::string>
Property;
119 template<
class Fixture>
146 #if CPPUNIT_NEED_DLL_DECL
147 #pragma warning( pop )
150 #endif // CPPUNIT_HELPER_TESTSUITEBUILDERCONTEXT_H
#define CPPUNIT_API
Definition: CppUnitApi.h:27
Context used when creating test suite in HelperMacros.
Definition: TestSuiteBuilderContext.h:29
const TestNamer & m_namer
Definition: TestSuiteBuilderContext.h:107
Abstract TestFixture factory (Implementation).
Definition: TestFixtureFactory.h:16
#define CPPUNIT_STATIC_CAST(TargetType, pointer)
Definition: Portability.h:87
std::vector< Property > Properties
Definition: TestSuiteBuilderContext.h:104
TestSuite & m_suite
Definition: TestSuiteBuilderContext.h:106
A Composite of Tests.
Definition: TestSuite.h:40
TestFixture * makeTestFixture() const
Definition: TestSuiteBuilderContext.cpp:49
Properties m_properties
Definition: TestSuiteBuilderContext.h:111
Wraps a test case with setUp and tearDown methods.
Definition: TestFixture.h:83
#define CPPUNIT_NS_BEGIN
Definition: Portability.h:105
#define CPPUNIT_NS_END
Definition: Portability.h:106
Names a test or a fixture suite.
Definition: TestNamer.h:38
TestFixtureFactory & m_factory
Definition: TestSuiteBuilderContext.h:108
std::pair< std::string, std::string > Property
Definition: TestSuiteBuilderContext.h:103
Base class for all test objects.
Definition: Test.h:25
FixtureType * makeFixture() const
Returns a new TestFixture instance.
Definition: TestSuiteBuilderContext.h:136
Fixture FixtureType
Definition: TestSuiteBuilderContext.h:123
std::string getTestNameFor(const std::string &testMethodName, const T &value) const
Returns the name of the test for the specified method with the corresponding parameter.
Definition: TestSuiteBuilderContext.h:80
TestSuiteBuilderContext(TestSuiteBuilderContextBase &contextBase)
Definition: TestSuiteBuilderContext.h:125
Type-sage context used when creating test suite in HelperMacros.
Definition: TestSuiteBuilderContext.h:120