]> SALOME platform Git repositories - modules/med.git/commitdiff
Salome HOME
[salome test] Install tests
authorCédric Aguerre <cedric.aguerre@edf.fr>
Mon, 18 Apr 2016 16:47:31 +0000 (18:47 +0200)
committerCédric Aguerre <cedric.aguerre@edf.fr>
Mon, 18 Apr 2016 17:03:54 +0000 (19:03 +0200)
CMakeLists.txt
CTestTestfileInstall.cmake [new file with mode: 0644]
src/MEDCalculator/Test/CMakeLists.txt
src/MEDCalculator/Test/CTestTestfileInstall.cmake

index 54fbb953f70ae48fe801418bffede89b8bbc7149..f655ba55adb01c5a3558f841bfbfe082c1eba6c4 100644 (file)
@@ -109,7 +109,7 @@ IF(SALOME_BUILD_GUI)
       FIND_PACKAGE(SalomeQt4 REQUIRED COMPONENTS QtCore QtGui)
     ELSE()
       FIND_PACKAGE(SalomeQt5 REQUIRED)
-    ENDIF()    
+    ENDIF()
 ENDIF(SALOME_BUILD_GUI)
 
 IF(SALOME_MED_ENABLE_PYTHON)
@@ -229,7 +229,7 @@ IF(SALOME_USE_MPI)
   LIST(APPEND _${PROJECT_NAME}_exposed_targets paramedcouplingcorba paramedmemcompo)
 ENDIF()
 
-LIST(APPEND _${PROJECT_NAME}_exposed_targets 
+LIST(APPEND _${PROJECT_NAME}_exposed_targets
     medcouplingcorba medcouplingclient medcalculator MEDFactoryEngine)
 IF(SALOME_MED_ENABLE_PYTHON)
   LIST(APPEND _${PROJECT_NAME}_exposed_targets medcalculatorspython)
@@ -274,11 +274,11 @@ SET(CONF_INCLUDE_DIRS "${CMAKE_INSTALL_PREFIX}/${INSTALL_INCLUDE_DIR}")
 
 # Build variables that will be expanded when configuring Salome<MODULE>Config.cmake:
 IF(NOT SALOME_GUI_BUILD_WITH_QT5)
-   SALOME_CONFIGURE_PREPARE(MEDCoupling Qt4 MPI omniORB CppUnit Graphviz Doxygen Sphinx  
-                                                                       PThread Python)
- ELSE()                     
-   SALOME_CONFIGURE_PREPARE(MEDCoupling Qt5 MPI omniORB CppUnit Graphviz Doxygen Sphinx  
-                                                                       PThread Python)
+   SALOME_CONFIGURE_PREPARE(MEDCoupling Qt4 MPI omniORB CppUnit Graphviz Doxygen Sphinx
+                                                                        PThread Python)
+ ELSE()
+   SALOME_CONFIGURE_PREPARE(MEDCoupling Qt5 MPI omniORB CppUnit Graphviz Doxygen Sphinx
+                                                                        PThread Python)
 ENDIF()
 
 CONFIGURE_PACKAGE_CONFIG_FILE(${PROJECT_NAME}Config.cmake.in
@@ -286,7 +286,7 @@ CONFIGURE_PACKAGE_CONFIG_FILE(${PROJECT_NAME}Config.cmake.in
     INSTALL_DESTINATION "${SALOME_INSTALL_CMAKE_LOCAL}"
     PATH_VARS CONF_INCLUDE_DIRS SALOME_INSTALL_CMAKE_LOCAL CMAKE_INSTALL_PREFIX
        KERNEL_ROOT_DIR GUI_ROOT_DIR MEDCOUPLING_ROOT_DIR QT_ROOT_DIR MPI_ROOT_DIR
-       OMNIORB_ROOT_DIR PTHREAD_ROOT_DIR SWIG_ROOT_DIR PYTHON_ROOT_DIR CPPUNIT_ROOT_DIR 
+       OMNIORB_ROOT_DIR PTHREAD_ROOT_DIR SWIG_ROOT_DIR PYTHON_ROOT_DIR CPPUNIT_ROOT_DIR
        GRAPHVIZ_ROOT_DIR DOXYGEN_ROOT_DIR SPHINX_ROOT_DIR)
 
 WRITE_BASIC_PACKAGE_VERSION_FILE(${PROJECT_BINARY_DIR}/${PROJECT_NAME}ConfigVersion.cmake
@@ -302,3 +302,8 @@ INSTALL(FILES
 # Install the export set for use with the install-tree
 INSTALL(EXPORT ${PROJECT_NAME}TargetGroup DESTINATION "${SALOME_INSTALL_CMAKE_LOCAL}"
         FILE ${PROJECT_NAME}Targets.cmake)
+
+# Application tests
+INSTALL(FILES CTestTestfileInstall.cmake
+  DESTINATION ${SALOME_INSTALL_SCRIPT_SCRIPTS}/test
+  RENAME CTestTestfile.cmake)
diff --git a/CTestTestfileInstall.cmake b/CTestTestfileInstall.cmake
new file mode 100644 (file)
index 0000000..65850b7
--- /dev/null
@@ -0,0 +1,23 @@
+# Copyright (C) 2016  CEA/DEN, EDF R&D
+#
+# This library is free software; you can redistribute it and/or
+# modify it under the terms of the GNU Lesser General Public
+# License as published by the Free Software Foundation; either
+# version 2.1 of the License, or (at your option) any later version.
+#
+# This library is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+# Lesser General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public
+# License along with this library; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
+#
+# See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+#
+
+SET(COMPONENT_NAME MEDCalc)
+SET(TIMEOUT        300)
+
+SUBDIRS(MEDCalculator)
index 0043ee90a7b0ffa6adc3b0263a9352bfcc09baf6..e7e937c4ec1220ecafd477b8759bba0402588250 100644 (file)
@@ -45,7 +45,7 @@ INSTALL(TARGETS TestMEDCalculator DESTINATION ${SALOME_INSTALL_BINS})
 
 # Application tests
 
-SET(TEST_INSTALL_DIRECTORY ${SALOME_INSTALL_SCRIPT_SCRIPTS}/test/MEDCoupling/MEDCalculator)
+SET(TEST_INSTALL_DIRECTORY ${SALOME_INSTALL_SCRIPT_SCRIPTS}/test/MEDCalculator)
 INSTALL(TARGETS TestMEDCalculator DESTINATION ${TEST_INSTALL_DIRECTORY})
 
 INSTALL(FILES CTestTestfileInstall.cmake
index 20cb6a16f8e3fc31fd521ecd21a0f45f688e0db7..e79a45278935f121ef1e5953472efcebde744c5a 100644 (file)
 # See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
 #
 
-ADD_TEST(TestMEDCalculator TestMEDCalculator)
-SET_TESTS_PROPERTIES(TestMEDCalculator PROPERTIES LABELS "${COMPONENT_NAME}")
+SET(TEST_NAMES
+  TestMEDCalculator
+)
+
+FOREACH(tfile ${TEST_NAMES})
+  SET(TEST_NAME ${COMPONENT_NAME}_${tfile})
+  ADD_TEST(${TEST_NAME} ${tfile})
+  SET_TESTS_PROPERTIES(${TEST_NAME} PROPERTIES
+    LABELS "${COMPONENT_NAME}"
+    TIMEOUT ${TIMEOUT}
+    )
+ENDFOREACH()