Skip to content
Snippets Groups Projects
Commit 0425638f authored by Julien Malik's avatar Julien Malik
Browse files

ENH: use the CommandLineLauncher for the application tests

parent c8875e39
Branches
Tags
No related merge requests found
set(CXX_TEST_PATH ${EXECUTABLE_OUTPUT_PATH})
set(INPUTDATA ${OTB_DATA_ROOT}/Input) set(INPUTDATA ${OTB_DATA_ROOT}/Input)
set(TEMP ${OTB_BINARY_DIR}/Testing/Temporary) set(TEMP ${OTB_BINARY_DIR}/Testing/Temporary)
if(WIN32) add_subdirectory(Util)
add_definitions(-DWIN32)
endif(WIN32)
# ---------------- Smoothing example test
set(APPLICATIONS_TESTS ${CXX_TEST_PATH}/otbWrapperExampleTests_Smoothing)
add_test(NAME exTvRescaleTest add_test(NAME exTvRescaleTest
COMMAND otbApplicationLauncherCommandLine COMMAND otbApplicationLauncherCommandLine
...@@ -20,24 +13,15 @@ add_test(NAME exTvRescaleTest ...@@ -20,24 +13,15 @@ add_test(NAME exTvRescaleTest
--outmax 150 ) --outmax 150 )
add_test(NAME exTvSmoothingTest add_test(NAME exTvSmoothingTest
COMMAND otbWrapperExampleTests COMMAND otbApplicationLauncherCommandLine
otbSmoothingTest Smoothing
$<TARGET_FILE_DIR:otbapp_Smoothing> --modulePath $<TARGET_FILE_DIR:otbapp_Smoothing>
${INPUTDATA}/poupees.tif --in ${INPUTDATA}/poupees.tif
${TEMP}/owTvSmoothingTest2.tif ) --out ${TEMP}/owTvSmoothingTest2.tif
--type mean)
add_test(NAME exTvReadImageInfoTest add_test(NAME exTvReadImageInfoTest
COMMAND otbApplicationLauncherCommandLine COMMAND otbApplicationLauncherCommandLine
ReadImageInfo ReadImageInfo
--modulePath $<TARGET_FILE_DIR:otbapp_ReadImageInfo> --modulePath $<TARGET_FILE_DIR:otbapp_ReadImageInfo>
--in ${INPUTDATA}/poupees.tif ) --in ${INPUTDATA}/poupees.tif )
add_executable(otbWrapperExampleTests
otbWrapperExampleTests.cxx
otbRescaleTest.cxx
otbSmoothingTest.cxx
otbReadImageInfoTest.cxx )
target_link_libraries(otbWrapperExampleTests OTBApplicationEngine OTBTesting)
add_test(NAME exTvRescaleTest
COMMAND otbApplicationLauncherCommandLine
Rescale
--modulePath $<TARGET_FILE_DIR:otbapp_Rescale>
--in ${INPUTDATA}/poupees.tif
--out ${TEMP}/owTvRescaleTest.tif
--outmin 20
--outmax 150 )
add_test(NAME exTvSmoothingTest
COMMAND otbApplicationLauncherCommandLine
Smoothing
--modulePath $<TARGET_FILE_DIR:otbapp_Smoothing>
--in ${INPUTDATA}/poupees.tif
--out ${TEMP}/owTvSmoothingTest2.tif
--type mean)
add_test(NAME exTvReadImageInfoTest
COMMAND otbApplicationLauncherCommandLine
ReadImageInfo
--modulePath $<TARGET_FILE_DIR:otbapp_ReadImageInfo>
--in ${INPUTDATA}/poupees.tif )
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment