CTK  0.1.0
The Common Toolkit is a community effort to provide support code for medical image analysis, surgical navigation, and related projects.
Classes | Macros
ctkTestApplication.h File Reference
#include <QApplication>
#include <QVector>
#include <QByteArray>
#include <QTimer>
#include "ctkWidgetsExport.h"
Include dependency graph for ctkTestApplication.h:

Go to the source code of this file.

Classes

class  ctkTestApplication
 

Macros

#define QCTK_DECLARE_TEST(TEST_NAME)
 Helper macro allowing to declare a test. More...
 
#define QCTK_EXIT_TEST(_status)
 Helper macro allowing to exit the event loop specifying a return code. More...
 
#define QCTK_RUN_TEST(TEST_NAME)
 Helper macro allowing to define a test. More...
 

Macro Definition Documentation

◆ QCTK_DECLARE_TEST

#define QCTK_DECLARE_TEST (   TEST_NAME)
Value:
namespace \
{ \
class _TEST_NAME : public ctkTestApplication \
{ \
public: \
_TEST_NAME(int _argc, char * _argv []): \
ctkTestApplication(_argc, _argv){} \
virtual void runTest(); \
}; \
\
void _TEST_NAME::runTest() \

Helper macro allowing to declare a test.

Definition at line 50 of file ctkTestApplication.h.

◆ QCTK_EXIT_TEST

#define QCTK_EXIT_TEST (   _status)
Value:

Helper macro allowing to exit the event loop specifying a return code.

Definition at line 75 of file ctkTestApplication.h.

◆ QCTK_RUN_TEST

#define QCTK_RUN_TEST (   TEST_NAME)
Value:
} \
\
int TEST_NAME(int _argc, char * _argv [] ) \
{ \
_TEST_NAME app(_argc, _argv); \
QTimer::singleShot(0, &app, SLOT(runTestSlot())); \
return _TEST_NAME::exec(); \
}

Helper macro allowing to define a test.

Definition at line 64 of file ctkTestApplication.h.