source: trunk/contrib/cppunit-1.12.2/include/cppunit/extensions/RepeatedTest.h @ 876

Last change on this file since 876 was 876, checked in by sam, 9 years ago

contrib: add a precompiled Win32 version of CppUnit and update build system
accordingly.

File size: 782 bytes
Line 
1#ifndef CPPUNIT_EXTENSIONS_REPEATEDTEST_H
2#define CPPUNIT_EXTENSIONS_REPEATEDTEST_H
3
4#include <cppunit/Portability.h>
5#include <cppunit/extensions/TestDecorator.h>
6
7CPPUNIT_NS_BEGIN
8
9
10class Test;
11class TestResult;
12
13
14/*! \brief Decorator that runs a test repeatedly.
15 *
16 * Does not assume ownership of the test it decorates
17 */
18class CPPUNIT_API RepeatedTest : public TestDecorator
19{
20public:
21  RepeatedTest( Test *test,
22                int timesRepeat ) :
23      TestDecorator( test ),
24      m_timesRepeat(timesRepeat)
25  {
26  }
27
28  void run( TestResult *result );
29
30  int countTestCases() const;
31
32private:
33  RepeatedTest( const RepeatedTest & );
34  void operator=( const RepeatedTest & );
35
36  const int m_timesRepeat;
37};
38
39
40CPPUNIT_NS_END
41
42
43#endif // CPPUNIT_EXTENSIONS_REPEATEDTEST_H
Note: See TracBrowser for help on using the repository browser.