Workspace 6.21.5
|
Namespace in which all testing code resides. More...
Classes | |
class | MockLogStream |
class | StdCapture |
class | TestHarness |
Basic test harness for running test cases. More... | |
class | TestSuite |
Class for implementing a suite of related tests. More... | |
class | TestWorkspaceAssertionFile |
This class is designed to simplify the use of loading workspace test files for use as test cases. More... | |
Functions | |
template<typename T > | |
bool | inputExists (const DataExecution::Operation &op, const QString &name, bool isScalar) |
template<typename T > | |
bool | outputExists (const DataExecution::Operation &op, const QString &name) |
All testing code is in its own separate namespace. The Testing namespace is distinct from the TestRunner namespace because the latter contains the code needed for running tests, whereas the former contains just the test harness code which has no reliance on anything in TestRunner. Thus, client test code should define all their tests in the Testing namespace so that only those symbols made visible by the client test code will be visible to the compiler (apart from the TestHarness and TestSuite classes defined for the sole purpose of simplifying the writing of tests).
bool inputExists | ( | const DataExecution::Operation & | op, |
const QString & | name, | ||
bool | isScalar | ||
) |
T | The expected data type of the input. |
op | The operation for which we are testing the existence of an input. |
name | The expected name of the input. |
isScalar | Whether or not the input is expected to be scalar. If false, the operation is expected to be an array input. |
bool outputExists | ( | const DataExecution::Operation & | op, |
const QString & | name | ||
) |
T | The expected data type of the output. |
op | The operation for which we are testing the existence of an output. |
name | The expected name of the output. |