Torque2D Reference
Classes | Typedefs | Functions
JsonTest Namespace Reference

Unit testing framework. More...

Classes

class  Failure
 
struct  PredicateContext
 
class  Runner
 
class  TestCase
 
class  TestResult
 

Typedefs

typedef TestCase *(* TestCaseFactory) ()
 Function pointer type for TestCase factory. More...
 

Functions

TestResultcheckStringEqual (TestResult &result, const std::string &expected, const std::string &actual, const char *file, unsigned int line, const char *expr)
 
template<typename T >
TestResultcheckEqual (TestResult &result, const T &expected, const T &actual, const char *file, unsigned int line, const char *expr)
 

Detailed Description

Unit testing framework.

Warning
: all assertions are non-aborting, test case execution will continue even if an assertion namespace. This constraint is for portability: the framework needs to compile on Visual Studio 6 and must not require exception usage.

Typedef Documentation

typedef TestCase*(* TestCaseFactory) ()

Function pointer type for TestCase factory.

Function Documentation

TestResult& JsonTest::checkEqual ( TestResult result,
const T &  expected,
const T &  actual,
const char *  file,
unsigned int  line,
const char *  expr 
)
TestResult & checkStringEqual ( TestResult result,
const std::string &  expected,
const std::string &  actual,
const char *  file,
unsigned int  line,
const char *  expr 
)