Medical Imaging Interaction Toolkit
2016.11.0
Medical Imaging Interaction Toolkit
|
Test fixture for parameterized tests. More...
#include <mitkTestFixture.h>
Inherits TestFixture.
Inherited by mitkAnisotropicIterativeClosestPointRegistrationTestSuite, mitkArbitraryTimeGeometryTestSuite, mitkArrayTypeConversionTestSuite, mitkBaseGeometryTestSuite, mitkClassificationTestSuite, mitkColorSequenceRainbowTestSuite, mitkCompositePixelValueToStringTestSuite, mitkCovarianceMatrixCalculatorTestSuite, mitkDICOMDCMTKTagScannerTestSuite, mitkDICOMLocaleTestSuite, mitkDICOMPropertyTestSuite, mitkDICOMTagPathTestSuite, mitkEqualTestSuite, mitkExampleDataStructureReaderWriterTestSuite, mitkExampleDataStructureTestSuite, mitkFloatToStringTestSuite, mitkGeometry3DEqualTestSuite, mitkGeometryDataIOTestSuite, mitkGlobalFeaturesTestSuite, mitkGlobalFeaturesTestSuite, mitkImageCastTestSuite, mitkImageEqualTestSuite, mitkImageToItkTestSuite, mitkImageToSurfaceFilterTestSuite, mitkImageToUnstructuredGridFilterTestSuite, mitkIOUtilTestSuite, mitkItkImageIOTestSuite, mitkLevelWindowManagerCppUnitTestSuite, mitkLibSVMClassifierTestSuite, mitkLineTestSuite, mitkLookupTableTestSuite, mitkMatrixTypeConversionTestSuite, mitkNodePredicateDataPropertyTestSuite, mitkPlanarFigureInteractionTestSuite, mitkPlaneGeometryTestSuite, mitkPointSetDataInteractorTestSuite, mitkPointSetEqualTestSuite, mitkPointSetOnEmptyTestSuite, mitkPointSetPointOperationsTestSuite, mitkPointSetTestSuite, mitkPointTypeConversionTestSuite, mitkProgressBarTestSuite, mitkPropertyNameHelperTestSuite, mitkPropertyPersistenceInfoTestSuite, mitkPropertyPersistenceTestSuite, mitkProportionalTimeGeometryTestSuite, mitkRawImageFileReaderTestSuite, mitkRTDoseReaderTestSuite, mitkRTStructureSetReaderTestSuite, mitkSceneIOTest2Suite, mitkSliceNavigationControllerTestSuite, mitkSmoothedClassProbabilitesTestSuite, mitkSmoothedClassProbabilitesTestSuite, mitkSplineVtkMapper3DTestSuite, mitkSTLFileReaderTestSuite, mitkSurfaceEqualTestSuite, mitkSurfaceToImageFilterTestSuite, mitkSurfaceVtkMapper2D3DTestSuite, mitkSurfaceVtkMapper2DTestSuite, mitkTemporoSpatialStringPropertyTestSuite, mitkUnstructuredGridClusteringFilterTestSuite, mitkUnstructuredGridToUnstructuredGridFilterTestSuite, mitkVectorPropertySerializerTestSuite, mitkVectorPropertyTestSuite, mitkVectorTypeConversionTestSuite, mitkVigraRandomForestTestSuite, and QmitkDataStorageListModelTestSuite.
Protected Member Functions | |
std::vector< std::string > | GetTestParameter () const |
Get parameters for this test fixture. More... | |
Static Protected Member Functions | |
static std::string | GetTestDataFilePath (const std::string &testData) |
Get the absolute path for test data. More... | |
Test fixture for parameterized tests.
This class is a drop-in replacement for CppUnit::TextFixture and enables test methods to access individual parameters. You can also invoke one method multiple times with different parameters.
The following simple example creates a single test without custom parameters:
The following example creates a test class containing only one test method, but the associated test suite contains three tests, using different parameters for each call of the same method. Use the macro MITK_PARAMETERIZED_TEST_1 only if you know what you are doing. If you are not sure, use MITK_TEST instead.
Definition at line 90 of file mitkTestFixture.h.
|
inlinestaticprotected |
Get the absolute path for test data.
testData | The realative path in the MITK test data repository. |
Definition at line 111 of file mitkTestFixture.h.
References MITK_DATA_DIR.
|
inlineprotected |
Get parameters for this test fixture.
This method can be called in tests added via the MITK_PARAMETERIZED_TEST macro or one of its variants.
std::string
parameters passed to previous calls of the MITK_PARAMETERIZED_TEST macro or one of its variants. Definition at line 103 of file mitkTestFixture.h.