diff --git a/Code/Common/otbGISConnectionImplementation.h b/Code/Common/otbGISConnectionImplementation.h index 4c484b690e65df49b691e0b3a351d07583f6f19d..bfd9f61543aee0a15ce1b6a21a648046b95c5ee5 100644 --- a/Code/Common/otbGISConnectionImplementation.h +++ b/Code/Common/otbGISConnectionImplementation.h @@ -73,7 +73,7 @@ protected: /** Constructor */ GISConnectionImplementation(){}; /** Destructor */ - virtual ~GISConnectionImplementation(){} + virtual ~GISConnectionImplementation(){}; private: GISConnectionImplementation(const Self &); //purposely not implemented diff --git a/Testing/Code/Common/CMakeLists.txt b/Testing/Code/Common/CMakeLists.txt index 7859d8afecb9ca4eaf3bfa6e63d6770be27e21fc..e720682bd5707f88e034a26d85b21973725b257c 100644 --- a/Testing/Code/Common/CMakeLists.txt +++ b/Testing/Code/Common/CMakeLists.txt @@ -35,6 +35,7 @@ SET(COMMON_TESTS11 ${CXX_TEST_PATH}/otbCommonTests11) IF(OTB_COMPILE_MUPARSER) SET(COMMON_TESTS12 ${CXX_TEST_PATH}/otbCommonTests12) ENDIF(OTB_COMPILE_MUPARSER) +SET(COMMON_TESTS8 ${CXX_TEST_PATH}/otbCommonTests13) # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ otbCommonTests1 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ @@ -910,6 +911,12 @@ Bidfeud0 ) +# ---------------- otbGISTableSource ---------------------# +ADD_TEST(coTuLabelMapSourceNew ${COMMON_TESTS10} +otbGISTableSourceNew +) + + ENDIF(OTB_USE_PQXX) # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ @@ -1003,6 +1010,14 @@ IF(OTB_COMPILE_MUPARSER) ENDIF(OTB_COMPILE_MUPARSER) +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ otbCommonTests13 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + + + + + # ------- Fichiers sources CXX ----------------------------------- SET(BasicCommon_SRCS1 otbCommonTests1.cxx @@ -1143,6 +1158,7 @@ otbGISTableToLabelMapFilterNew.cxx otbGISTableToVectorDataFilterNew.cxx otbLabelMapToGISTableFilter.cxx otbGISTableToVectorDataFilter.cxx +otbGISTableSourceNew.cxx ) ENDIF(OTB_USE_PQXX) @@ -1172,6 +1188,11 @@ otbParserTest.cxx ) ENDIF(OTB_COMPILE_MUPARSER) + +SET(BasicCommon_SRCS13 +otbCommonTests13.cxx +) + OTB_ADD_EXECUTABLE(otbCommonTests1 "${BasicCommon_SRCS1}" "OTBIO;OTBTesting") OTB_ADD_EXECUTABLE(otbCommonTests2 "${BasicCommon_SRCS2}" "OTBIO;OTBTesting") OTB_ADD_EXECUTABLE(otbCommonTests3 "${BasicCommon_SRCS3}" "OTBIO;OTBTesting") @@ -1194,4 +1215,6 @@ IF(OTB_COMPILE_MUPARSER) OTB_ADD_EXECUTABLE(otbCommonTests12 "${BasicCommon_SRCS12}" "OTBIO;OTBTesting") ENDIF(OTB_COMPILE_MUPARSER) +OTB_ADD_EXECUTABLE(otbCommonTests13 "${BasicCommon_SRCS13}" "OTBIO;OTBTesting") + ENDIF( NOT OTB_DISABLE_CXX_TESTING AND BUILD_TESTING ) diff --git a/Testing/Code/Common/otbCommonTests10.cxx b/Testing/Code/Common/otbCommonTests10.cxx index 512e1f4ab38a17365275f31f225c8c7ca0b219a2..fa08d84f76840c28b7ba50c8b71f6c8c21e9997c 100644 --- a/Testing/Code/Common/otbCommonTests10.cxx +++ b/Testing/Code/Common/otbCommonTests10.cxx @@ -39,4 +39,5 @@ void RegisterTests() REGISTER_TEST(otbGISTableToLabelMapFilterNew); REGISTER_TEST(otbLabelMapToGISTableFilter); REGISTER_TEST(otbGISTableToVectorDataFilter); + REGISTER_TEST(otbGISTableSourceNew); } diff --git a/Testing/Code/Common/otbCommonTests13.cxx b/Testing/Code/Common/otbCommonTests13.cxx new file mode 100644 index 0000000000000000000000000000000000000000..fd1171dd7454d5da1e168c47ffa98b7d99a57892 --- /dev/null +++ b/Testing/Code/Common/otbCommonTests13.cxx @@ -0,0 +1,30 @@ +/*========================================================================= + + Program: ORFEO Toolbox + Language: C++ + Date: $Date$ + Version: $Revision$ + + + Copyright (c) Centre National d'Etudes Spatiales. All rights reserved. + See OTBCopyright.txt for details. + + + This software is distributed WITHOUT ANY WARRANTY; without even + the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR + PURPOSE. See the above copyright notices for more information. + +=========================================================================*/ + +// this file defines the otbCommonTest for the test driver +// and all it expects is that you have a function called RegisterTests +#if defined(_MSC_VER) +#pragma warning ( disable : 4786 ) +#endif + +#include "otbTestMain.h" + +void RegisterTests() +{ + // REGISTER_TEST(otbGISTableSourceNew); +} diff --git a/Testing/Code/Common/otbGISTableSourceNew.cxx b/Testing/Code/Common/otbGISTableSourceNew.cxx new file mode 100644 index 0000000000000000000000000000000000000000..8ed3fae20105d65e2d38a1e1cf24bdb84c733982 --- /dev/null +++ b/Testing/Code/Common/otbGISTableSourceNew.cxx @@ -0,0 +1,37 @@ +/*========================================================================= + + Program: ORFEO Toolbox + Language: C++ + Date: $Date$ + Version: $Revision$ + + + Copyright (c) Centre National d'Etudes Spatiales. All rights reserved. + See OTBCopyright.txt for details. + + + This software is distributed WITHOUT ANY WARRANTY; without even + the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR + PURPOSE. See the above copyright notices for more information. + +=========================================================================*/ +#include "itkExceptionObject.h" +#include "otbMacro.h" + +#include "otbGISTableSource.h" +#include "otbGISTable.h" +#include "otbPostGISConnectionImplementation.h" + +int otbGISTableSourceNew(int argc, char * argv[]) +{ + + typedef otb::PostGISConnectionImplementation GISConnectionType; + typedef otb::GISTable<GISConnectionType, double, 2> GISTableType; + + typedef otb::GISTableSource<GISTableType> GISTableSourceType; + + //Instantiation + GISTableSourceType::Pointer object = GISTableSourceType::New(); + + return EXIT_SUCCESS; +}