#include some macros from another file... INCLUDE(${CMAKE_SOURCE_DIR}/IJMacros.txt) #Change PROJECT_NAME to the name of your project PROJECT(BinaryWellComposedImageFilterTest) #The following lines are required to use Dart ENABLE_TESTING() INCLUDE(Dart) #Declare any external dependencies that your project may have here. #examples include: ITK, VTK, JPEG, PNG, OpenGL, ZLIB, Perl, Java #If you're not sure what name to use, look in the Modules directory of your #cmake install and check that a file named Find(Package).cmake exists SET(Required_Packages ITK ) #this foreach loads all of the packages that you specified as required. #It shouldn't need to be modified. FOREACH(Package ${Required_Packages}) LOADPACKAGE(${Package}) ENDFOREACH(Package) #Set any libraries that your project depends on. #examples: ITKCommon, VTKRendering, etc SET(Libraries ITKCommon ITKBasicFilters ITKStatistics ITKAlgorithms ITKIO itkgdcm ) #the following block of code is an example of how to build an executable in #cmake. Unmodified, it will add an executable called "MyExe" to the project. #MyExe will be built using the files MyClass.h and MyClass.cxx, and it will #be linked to all the libraries you specified above. #You can build more than one executable per project SET(Current2DExe "itkBinaryWellComposedImageFilter2DTest" ) ADD_EXECUTABLE(${Current2DExe} ${Current2DExe}) TARGET_LINK_LIBRARIES(${Current2DExe} ${Libraries}) SET(Current3DExe "itkBinaryWellComposedImageFilter3DTest" ) ADD_EXECUTABLE(${Current3DExe} ${Current3DExe}) TARGET_LINK_LIBRARIES(${Current3DExe} ${Libraries}) ADD_TEST(Run1 ${Current2DExe} ${BinaryWellComposedImageFilterTest_SOURCE_DIR}/random2d.mha ${BinaryWellComposedImageFilterTest_BINARY_DIR}/random2d_out.mha) ADD_TEST(Run2 ${Current3DExe} ${BinaryWellComposedImageFilterTest_SOURCE_DIR}/brain3d.mha ${BinaryWellComposedImageFilterTest_BINARY_DIR}/brain3d_out.mha) ADD_TEST(CompareImage1 ImageCompare ${BinaryWellComposedImageFilterTest_SOURCE_DIR}/repaired2d.mha ${BinaryWellComposedImageFilterTest_BINARY_DIR}/random2d_out.mha) ADD_TEST(CompareImage2 ImageCompare ${BinaryWellComposedImageFilterTest_SOURCE_DIR}/repaired3d.mha ${BinaryWellComposedImageFilterTest_BINARY_DIR}/brain3d_out.mha)