From 37d113d79592ee8ad38ccab6fad61e3a0b80c05f Mon Sep 17 00:00:00 2001
From: Marina Bertolino <marina.bertolino@c-s.fr>
Date: Wed, 25 Oct 2017 10:58:12 +0200
Subject: [PATCH] TEST: add 3 tests for DynamicConvert app

---
 .../AppImageUtils/test/CMakeLists.txt         | 39 ++++++++++++++++++-
 1 file changed, 38 insertions(+), 1 deletion(-)

diff --git a/Modules/Applications/AppImageUtils/test/CMakeLists.txt b/Modules/Applications/AppImageUtils/test/CMakeLists.txt
index 7c33a6b68e..020d9efe33 100644
--- a/Modules/Applications/AppImageUtils/test/CMakeLists.txt
+++ b/Modules/Applications/AppImageUtils/test/CMakeLists.txt
@@ -53,7 +53,7 @@ otb_test_application(NAME apTvUtConvertWithScaling
                              -type linear
                      VALID   --compare-image ${NOTOL}
                              ${INPUTDATA}/apTvUtConvertWithScalingOutput.tif
-                	     ${TEMP}/apTvUtConvertWithScalingOutput.tif
+                             ${TEMP}/apTvUtConvertWithScalingOutput.tif
 )
 
 otb_test_application(NAME apTvUtConvertExtendedFilename_readerGEOM
@@ -87,6 +87,43 @@ otb_test_application(NAME apTvUtConvertMonoChannel
                              ${INPUTDATA}/apTvUtConvertMonoChannelOutput.tif
                              ${TEMP}/apTvUtConvertMonoChannelOutput.tif)
 
+#----------- DynamicConvert TESTS ------------
+otb_test_application(NAME apTvUtDynamicConvertBasic
+                     APP DynamicConvert
+                     OPTIONS -in ${INPUTDATA}/QB_Toulouse_Ortho_XS.tif
+                             -out ${TEMP}/apTvUtDynamicConvertOutput.tif
+                             -type linear
+                             -channels rgb
+                             -channels.rgb.red 2
+                             -channels.rgb.green 3
+                             -channels.rgb.blue 1
+                     VALID   --compare-image ${NOTOL}
+                             ${INPUTDATA}/apTvUtConvertSelectChannelsRgbOutput.tif
+                             ${TEMP}/apTvUtDynamicConvertOutput.tif)
+
+otb_test_application(NAME apTvUtDynamicConvertLog2
+                     APP DynamicConvert
+                     OPTIONS -in ${INPUTDATA}/QB_Toulouse_Ortho_XS.tif
+                             -out ${TEMP}/apTvUtDynamicConvertLog2Output.tif
+                             -type log2
+                     VALID   --compare-image ${NOTOL}
+                             ${INPUTDATA}/apTvUtDynamicConvertLog2Output.tif
+                             ${TEMP}/apTvUtDynamicConvertLog2Output.tif)
+
+otb_test_application(NAME apTvUtDynamicConvertFloat
+                     APP DynamicConvert
+                     OPTIONS -in ${INPUTDATA}/ToulouseQuickBird_Extrait_1500_3750.tif
+                             -out ${TEMP}/apTvUtDynamicConvertFloatOutput.tif float
+                             -type linear
+                             -type.linear.gamma 2.2
+                             -outmin 0.0
+                             -outmax 1.0
+                             -quantile.low 0
+                             -quantile.high 4
+                     VALID   --compare-image ${NOTOL}
+                             ${INPUTDATA}/apTvUtDynamicConvertFloatOutput.tif
+                             ${TEMP}/apTvUtDynamicConvertFloatOutput.tif)
+
 #----------- PixelInfo TESTS ----------------
 
 #----------- ExtractROI TESTS ----------------
-- 
GitLab