From 818b0db6a2a88638b7a450378f8d4c280f32971e Mon Sep 17 00:00:00 2001
From: Cyrille Valladeau <cyrille.valladeau@c-s.fr>
Date: Tue, 24 Nov 2009 15:30:13 +0100
Subject: [PATCH] ENH : correct configurationtest

---
 Testing/Code/Common/otbConfigurationTest.cxx |  2 +-
 Testing/Code/Projections/otbSensorModel.cxx  |  2 +-
 Testing/Utilities/CMakeLists.txt             | 10 ++++++----
 3 files changed, 8 insertions(+), 6 deletions(-)

diff --git a/Testing/Code/Common/otbConfigurationTest.cxx b/Testing/Code/Common/otbConfigurationTest.cxx
index 7931da967c..1009b21cef 100644
--- a/Testing/Code/Common/otbConfigurationTest.cxx
+++ b/Testing/Code/Common/otbConfigurationTest.cxx
@@ -33,7 +33,7 @@ int otbConfigurationTest(int argc, char * argv[])
   
   std::cout << conf << std::endl;
   
-  if (lang != "fr_FR.UTF-8" || lang != "en_EN.UTF-8")
+  if( lang.compare("fr_FR.UTF-8") != 0  && lang.compare("en_EN.UTF-8") !=0 )
   {
     std::cout << "Locale language " << lang << std::endl;
     return EXIT_FAILURE;
diff --git a/Testing/Code/Projections/otbSensorModel.cxx b/Testing/Code/Projections/otbSensorModel.cxx
index 91526c615d..c26ebb198a 100644
--- a/Testing/Code/Projections/otbSensorModel.cxx
+++ b/Testing/Code/Projections/otbSensorModel.cxx
@@ -42,7 +42,7 @@ int otbSensorModel( int argc, char* argv[] )
 
   std::ofstream file;
   file.open(outFilename);
-  file << std::setprecision(15);
+  file << std::setprecision(20);
 
 
   typedef otb::VectorImage<double, 2> ImageType;
diff --git a/Testing/Utilities/CMakeLists.txt b/Testing/Utilities/CMakeLists.txt
index db6615dafa..60af30f912 100644
--- a/Testing/Utilities/CMakeLists.txt
+++ b/Testing/Utilities/CMakeLists.txt
@@ -30,16 +30,18 @@ SET(UTILITIES_TESTS ${CXX_TEST_PATH}/otbUtilitiesTests)
 IF(OTB_DATA_USE_LARGEINPUT)
 
 ADD_TEST(utTvOssimKeywordlistToulouseQuickBirdTest ${UTILITIES_TESTS}
---compare-list ${EPSILON_6}  ${BASELINE_FILES}/utOssimKeywordlistToulouseQuickBird.txt
-                        ${TEMP}/utOssimKeywordlistToulouseQuickBird.txt
+--ignore-order --compare-ascii ${EPSILON_6}  
+	       ${BASELINE_FILES}/utOssimKeywordlistToulouseQuickBird.txt
+	       ${TEMP}/utOssimKeywordlistToulouseQuickBird.txt
         ossimKeywordlistTest
         ${IMAGEDATA}/QUICKBIRD/TOULOUSE/000000128955_01_P001_PAN/02APR01105228-P1BS-000000128955_01_P001.TIF
         ${TEMP}/utOssimKeywordlistToulouseQuickBird.txt
         )
 
 ADD_TEST(utTvOssimKeywordlistBlossevilleIkonosTest ${UTILITIES_TESTS}
---compare-list ${NOTOL}  ${BASELINE_FILES}/utOssimKeywordlistBlossevilleIkonos.txt
-                        ${TEMP}/utOssimKeywordlistBlossevilleIkonos.txt
+--ignore-order --compare-ascii ${NOTOL} 
+	        ${BASELINE_FILES}/utOssimKeywordlistBlossevilleIkonos.txt
+		${TEMP}/utOssimKeywordlistBlossevilleIkonos.txt
         ossimKeywordlistTest
         ${IMAGEDATA}/IKONOS/BLOSSEVILLE/po_2619900_grn_0000000.tif
         ${TEMP}/utOssimKeywordlistBlossevilleIkonos.txt
-- 
GitLab