MoSync 3.3
MATest::TestCase Class Reference

A test case. More...

#include <MATest/Test.h>

List of all members.

Public Member Functions

 TestCase (const String &name)
virtual ~TestCase ()
virtual void open ()
virtual void close ()
virtual void start ()=0
void addTestListener (TestListener *testListener)
bool assert (const String &assertionName, bool success)
const StringgetName () const
void setSuite (TestSuite *suite)

Protected Attributes

TestSuitesuite
String name

Detailed Description

A test case.

Implement this class for each of your test cases. Use assert when testing assertions. Override open and close to initialize and deinitialize test case specific things. Override start for the tests.

Do not initialize any non-const variables in the constructor, as the test may be run more than once.


Constructor & Destructor Documentation

virtual MATest::TestCase::~TestCase ( ) [virtual]

Member Function Documentation

virtual void MATest::TestCase::open ( ) [virtual]
virtual void MATest::TestCase::close ( ) [virtual]
virtual void MATest::TestCase::start ( ) [pure virtual]
bool MATest::TestCase::assert ( const String assertionName,
bool  success 
)

Member Data Documentation

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines