CppUnit project page FAQ CppUnit home page

TestSuite.h
Go to the documentation of this file.
1 #ifndef CPPUNIT_TESTSUITE_H // -*- C++ -*-
2 #define CPPUNIT_TESTSUITE_H
3 
4 #include <cppunit/Portability.h>
5 
6 #if CPPUNIT_NEED_DLL_DECL
7 #pragma warning( push )
8 #pragma warning( disable: 4251 ) // X needs to have dll-interface to be used by clients of class Z
9 #endif
10 
11 #include <cppunit/TestComposite.h>
13 
15 
16 
17 #if CPPUNIT_NEED_DLL_DECL
18 // template class CPPUNIT_API std::vector<Test *>;
19 #endif
20 
21 
41 {
42 public:
43  static unsigned long disabledTests;
46  TestSuite( std::string name = "" );
47 
48  ~TestSuite();
49 
53  void addTest( Test *test );
54 
60  const CppUnitVector<Test *> &getTests() const;
61 
64  virtual void deleteContents();
65 
66  int getChildTestCount() const;
67 
68  Test *doGetChildTestAt( int index ) const;
69 
70  virtual bool filter(const Filter&);
71 
72 private:
73  CppUnitVector<Test *> m_tests;
74 };
75 
76 
78 
79 #if CPPUNIT_NEED_DLL_DECL
80 #pragma warning( pop )
81 #endif
82 
83 #endif // CPPUNIT_TESTSUITE_H
CppUnitVector< Test * > m_tests
Definition: TestSuite.h:73
A Composite of Tests.
Definition: TestComposite.h:17
Base class for all test objects.All test objects should be a subclass of Test. Some test objects...
Definition: Test.h:26
#define CPPUNIT_NS_END
Definition: Portability.h:120
static unsigned long disabledTests
Definition: TestSuite.h:43
#define CPPUNIT_NS_BEGIN
Definition: Portability.h:119
virtual Test * doGetChildTestAt(int index) const =0
Returns the child test of the specified valid index.
Use this filter to only run some of the registered tests.
Definition: Test.h:114
virtual int getChildTestCount() const =0
Returns the number of direct child of the test.
A Composite of Tests.It runs a collection of test cases. Here is an example.
Definition: TestSuite.h:40
virtual bool filter(const Filter &)=0
#define CPPUNIT_API
Definition: CppUnitApi.h:27

SourceForge Logo hosts this site. Send comments to:
CppUnit Developers