Salome HOME
0023505: Sigsegv with fuse on cylinder and cone
[modules/geom.git] / src / XAO / tests / CMakeLists.txt
index 244bccbaf0832d11885ebd2f2893d27ca0a935a8..15c9a5f3b2e458bca30a0d8bb94023dad270c44d 100644 (file)
@@ -1,9 +1,9 @@
-# Copyright (C) 2012-2013  CEA/DEN, EDF R&D, OPEN CASCADE
+# Copyright (C) 2012-2017  CEA/DEN, EDF R&D, OPEN CASCADE
 #
 # 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
@@ -17,7 +17,7 @@
 # See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
 #
 
-# --- options ---
+ADD_SUBDIRECTORY(data)
 
 # additional include directories
 INCLUDE_DIRECTORIES(
@@ -55,6 +55,19 @@ SET(TestXAO_SOURCES
 
 ADD_EXECUTABLE(TestXAO ${TestXAO_SOURCES})
 TARGET_LINK_LIBRARIES(TestXAO ${_link_LIBRARIES})
+
+SALOME_GENERATE_TESTS_ENVIRONMENT(tests_env)
+SET(TEST_INSTALL_DIRECTORY ${SALOME_INSTALL_SCRIPT_SCRIPTS}/test/xao)
+
 ADD_TEST(TestXAO TestXAO)
+SET_TESTS_PROPERTIES(TestXAO PROPERTIES ENVIRONMENT "XAO_DATA_DIR=${TEST_INSTALL_DIRECTORY}/data;${tests_env}")
 
 INSTALL(TARGETS TestXAO DESTINATION ${SALOME_INSTALL_BINS})
+
+# Application tests
+
+INSTALL(TARGETS TestXAO RUNTIME DESTINATION ${TEST_INSTALL_DIRECTORY})
+
+INSTALL(FILES CTestTestfileInstall.cmake
+        DESTINATION ${TEST_INSTALL_DIRECTORY}
+        RENAME CTestTestfile.cmake)