Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Mirrors
SuperElastix
Commits
b7de626d
Commit
b7de626d
authored
Apr 20, 2016
by
Kasper Marstal
Browse files
ENH: Move test code closer the source that is tested
parent
592250d5
Changes
9
Hide whitespace changes
Inline
Side-by-side
Modules/Components/itkImageRegistrationMethodv4/ModuleItkImageRegistrationMethodv4.cmake
View file @
b7de626d
...
...
@@ -15,8 +15,8 @@ set( ${MODULE}_LIBRARIES
# Export tests
set
(
${
MODULE
}
_TESTS
selxRegistrationItkv4Test.cxx
selxWBIRDemoTest.cxx
${${
MODULE
}
_SOURCE_DIR
}
/test/
selxRegistrationItkv4Test.cxx
${${
MODULE
}
_SOURCE_DIR
}
/test/
selxWBIRDemoTest.cxx
)
# Module source files
...
...
Testing/Uni
t/selxRegistrationItkv4Test.cxx
→
Modules/Components/itkImageRegistrationMethodv4/tes
t/selxRegistrationItkv4Test.cxx
View file @
b7de626d
File moved
Testing/Uni
t/selxWBIRDemoTest.cxx
→
Modules/Components/itkImageRegistrationMethodv4/tes
t/selxWBIRDemoTest.cxx
View file @
b7de626d
File moved
Testing/Uni
t/selxBlueprintTest.cxx
→
Modules/Core/Blueprints/tes
t/selxBlueprintTest.cxx
View file @
b7de626d
File moved
Testing/Uni
t/selxComponentFactoryTest.cxx
→
Modules/Core/ComponentInterface/tes
t/selxComponentFactoryTest.cxx
View file @
b7de626d
File moved
Testing/Uni
t/selxComponentInterfaceTest.cxx
→
Modules/Core/ComponentInterface/tes
t/selxComponentInterfaceTest.cxx
View file @
b7de626d
File moved
Testing/Uni
t/selxOverlordTest.cxx
→
Modules/Core/ComponentInterface/tes
t/selxOverlordTest.cxx
View file @
b7de626d
File moved
Modules/Core/ModuleCore.cmake
View file @
b7de626d
...
...
@@ -19,10 +19,10 @@ set( ${MODULE}_LIBRARIES
# Export tests
set
(
${
MODULE
}
_TESTS
selxBlueprintTest.cxx
selxComponentFactoryTest.cxx
selxComponentInterfaceTest.cxx
selxOverlordTest.cxx
${${
MODULE
}
_SOURCE_DIR
}
/Blueprints/test/
selxBlueprintTest.cxx
${${
MODULE
}
_SOURCE_DIR
}
/ComponentInterface/test/
selxComponentFactoryTest.cxx
${${
MODULE
}
_SOURCE_DIR
}
/ComponentInterface/test/
selxComponentInterfaceTest.cxx
${${
MODULE
}
_SOURCE_DIR
}
/ComponentInterface/test/
selxOverlordTest.cxx
)
# Module source files
...
...
Testing/Unit/CMakeLists.txt
View file @
b7de626d
...
...
@@ -35,7 +35,8 @@ configure_file(
ESCAPE_QUOTES
)
include_directories
(
${
CMAKE_CURRENT_BINARY_DIR
}
)
include_directories
(
${
CMAKE_CURRENT_SOURCE_DIR
}
)
# selxDataManager.h
include_directories
(
${
CMAKE_CURRENT_BINARY_DIR
}
)
# selxDataDirectories.h
add_library
(
DataManager selxDataManager.cxx
)
list
(
APPEND TEST_LIBRARIES
...
...
@@ -45,12 +46,12 @@ list( APPEND TEST_LIBRARIES
# ---------------------------------------------------------------------
# Build tests
foreach
(
SuperElastixUnitTestFile
n
ame
${
SUPERELASTIX_TESTS
}
)
foreach
(
SuperElastixUnitTestFile
N
ame
${
SUPERELASTIX_TESTS
}
)
# Build tests executables
string
(
REPLACE
".cxx"
""
SuperElastixUnitTest
${
SuperElastixUnitTestFile
n
ame
}
)
add_executable
(
${
SuperElastixUnitTest
}
${
SuperElastixUnitTestFile
n
ame
}
)
get_filename_component
(
SuperElastixUnitTest
${
SuperElastixUnitTestFile
N
ame
}
NAME
)
add_executable
(
${
SuperElastixUnitTest
}
${
SuperElastixUnitTestFile
N
ame
}
)
target_link_libraries
(
"
${
SuperElastixUnitTest
}
"
${
SUPERELASTIX_LIBRARIES
}
${
ITK_LIBRARIES
}
${
TEST_LIBRARIES
}
)
# Add GoogleTest to CTest
GTEST_ADD_TESTS
(
${
SuperElastixUnitTest
}
"--gtest_output=xml:
${
CMAKE_BINARY_DIR
}
/Testing/Unit/
${
SuperElastixUnitTest
}
.xml"
${
SuperElastixUnitTestFile
n
ame
}
)
GTEST_ADD_TESTS
(
${
SuperElastixUnitTest
}
"--gtest_output=xml:
${
CMAKE_BINARY_DIR
}
/Testing/Unit/
${
SuperElastixUnitTest
}
.xml"
${
SuperElastixUnitTestFile
N
ame
}
)
endforeach
()
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment