-# Copyright (C) 2010-2012 CEA/DEN, EDF R&D
+# Copyright (C) 2010-2015 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.
+# 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
# See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#
-SUBDIRS(Util
- 2D_viewer
- 3D_viewer
- ScalarMap
- DeformedShape
- ScalarMap_On_DeformedShape
- CutPlanes
- CutLines
- Vectors
- Plot3D
- IsoSurfaces
- MeshPresentation
- Animation
- GaussPoints
- StreamLines
- SWIG_scripts
- Tables
+# For make test
+
+SET(TIMEOUT 1000)
+SALOME_GENERATE_TESTS_ENVIRONMENT(tests_env)
+
+IF(NOT WIN32)
+ # Special case for the PV_PLUGIN_PATH environment variable:
+ # PV_PLUGIN_PATH=VAL_1;VAL_2;...;VAL_N
+ # But the ';' character is used as separator between variables (PATH, LD_LIBRARY_PATH, etc...)
+ # So we should shield a sequence ";/" by the '\' character.
+ STRING(REGEX REPLACE ";/" "\\\\;/" tests_env "${tests_env}")
+ENDIF(NOT WIN32)
+
+SET(SALOME_TEST_DRIVER "${KERNEL_ROOT_DIR}/bin/salome/appliskel/salome_test_driver.py")
+
+# Common part
+
+SET(TEST_DIRECTORIES
+ Util
+ 2D_viewer
+ 3D_viewer
+ ScalarMap
+ DeformedShape
+ ScalarMap_On_DeformedShape
+ CutPlanes
+ CutLines
+ Vectors
+ Plot3D
+ IsoSurfaces
+ MeshPresentation
+ Animation
+ GaussPoints
+ StreamLines
+ SWIG_scripts
+# Tables table reader is not used anymore and CSVReader
+# doesn't suport txt and xls formats, so switch off Tables tests
+ ImportMedField
+ united
+ bugs
+ imps
+ dump_study
)
+
+FOREACH(test_dir ${TEST_DIRECTORIES})
+ ADD_SUBDIRECTORY(${test_dir})
+ENDFOREACH()
+
+# Application tests
+INSTALL(FILES CTestTestfileInstall.cmake
+ DESTINATION ${SALOME_INSTALL_SCRIPT_SCRIPTS}/test/VisuPrs
+ RENAME CTestTestfile.cmake)