From b6df9f3718a37841b9c124d57b39ff9d063953d9 Mon Sep 17 00:00:00 2001 From: Nicolai Haug Date: Fri, 2 Jun 2023 13:15:17 +0200 Subject: [PATCH 1/3] Add unittests/sli2py_ignore directory --- testsuite/CMakeLists.txt | 11 ++++---- testsuite/do_tests.sh | 13 +++++++-- .../unittests/sli2py_ignore/CMakeLists.txt | 28 +++++++++++++++++++ 3 files changed, 44 insertions(+), 8 deletions(-) create mode 100644 testsuite/unittests/sli2py_ignore/CMakeLists.txt diff --git a/testsuite/CMakeLists.txt b/testsuite/CMakeLists.txt index b48284288b..5308bec175 100644 --- a/testsuite/CMakeLists.txt +++ b/testsuite/CMakeLists.txt @@ -26,10 +26,11 @@ set( TESTSUBDIRS musictests cpptests pytests - ) +) add_subdirectory( selftests ) add_subdirectory( unittests ) +add_subdirectory( unittests/sli2py_ignore ) add_subdirectory( regressiontests ) add_subdirectory( mpi_selftests/fail ) add_subdirectory( mpi_selftests/pass ) @@ -39,19 +40,19 @@ add_subdirectory( cpptests ) install( DIRECTORY ${TESTSUBDIRS} DESTINATION ${CMAKE_INSTALL_DATADIR}/testsuite - ) +) install( PROGRAMS do_tests.sh DESTINATION ${CMAKE_INSTALL_DATADIR}/testsuite - ) +) install( PROGRAMS nest_indirect nest_serial DESTINATION ${CMAKE_INSTALL_BINDIR} - ) +) install( FILES junit_xml.sh run_test.sh summarize_tests.py DESTINATION ${CMAKE_INSTALL_DATADIR}/testsuite - ) +) diff --git a/testsuite/do_tests.sh b/testsuite/do_tests.sh index be6616f307..4b2c425b63 100755 --- a/testsuite/do_tests.sh +++ b/testsuite/do_tests.sh @@ -331,9 +331,16 @@ if test "${PYTHON}"; then tests_collect="$tests_collect py" fi for test_ext in ${tests_collect} ; do - for test_name in $(ls "${TEST_BASEDIR}/unittests/" | grep ".*\.${test_ext}\$") ; do - run_test "unittests/${test_name}" "${CODES_SUCCESS}" "${CODES_SKIPPED}" "${CODES_FAILURE}" - done + for test_name in $(ls "${TEST_BASEDIR}/unittests/" | grep ".*\.${test_ext}\$") ; do + run_test "unittests/${test_name}" "${CODES_SUCCESS}" "${CODES_SKIPPED}" "${CODES_FAILURE}" + done + for test_name in $(ls "${TEST_BASEDIR}/unittests/sli2py_ignore/" | grep ".*\.${test_ext}\$") ; do + run_test "unittests/sli2py_ignore/${test_name}" "${CODES_SUCCESS}" "${CODES_SKIPPED}" "${CODES_FAILURE}" + done +done + +for test_ext in ${tests_collect} ; do + done junit_close diff --git a/testsuite/unittests/sli2py_ignore/CMakeLists.txt b/testsuite/unittests/sli2py_ignore/CMakeLists.txt new file mode 100644 index 0000000000..89e0e18cb3 --- /dev/null +++ b/testsuite/unittests/sli2py_ignore/CMakeLists.txt @@ -0,0 +1,28 @@ +# testsuite/unittests/sli2py_ignore/CMakeLists.txt +# +# This file is part of NEST. +# +# Copyright (C) 2004 The NEST Initiative +# +# NEST is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 2 of the License, or +# (at your option) any later version. +# +# NEST 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 General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with NEST. If not, see . + +# add unittests/sli2py_ignore files +file( GLOB scripts RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} *.sli ) + +foreach( script ${scripts} ) + add_test( NAME unittests/sli2py_ignore/${script} + COMMAND ${CMAKE_INSTALL_FULL_BINDIR}/nest + ${CMAKE_INSTALL_FULL_DOCDIR}/unittests/sli2py_ignore/${script} # use the installed version + ) +endforeach() From 7ccc355d01a2c4d7be9e09cdc1b548600c134fef Mon Sep 17 00:00:00 2001 From: Nicolai Haug Date: Fri, 2 Jun 2023 13:24:19 +0200 Subject: [PATCH 2/3] Add regressiontests/sli2py_ignore directory --- testsuite/CMakeLists.txt | 1 + testsuite/do_tests.sh | 3 ++ .../sli2py_ignore/CMakeLists.txt | 28 +++++++++++++++++++ 3 files changed, 32 insertions(+) create mode 100644 testsuite/regressiontests/sli2py_ignore/CMakeLists.txt diff --git a/testsuite/CMakeLists.txt b/testsuite/CMakeLists.txt index 5308bec175..8553593ca8 100644 --- a/testsuite/CMakeLists.txt +++ b/testsuite/CMakeLists.txt @@ -32,6 +32,7 @@ add_subdirectory( selftests ) add_subdirectory( unittests ) add_subdirectory( unittests/sli2py_ignore ) add_subdirectory( regressiontests ) +add_subdirectory( regressiontests/sli2py_ignore ) add_subdirectory( mpi_selftests/fail ) add_subdirectory( mpi_selftests/pass ) add_subdirectory( mpitests ) diff --git a/testsuite/do_tests.sh b/testsuite/do_tests.sh index 4b2c425b63..08b7205e31 100755 --- a/testsuite/do_tests.sh +++ b/testsuite/do_tests.sh @@ -355,6 +355,9 @@ for test_ext in ${tests_collect} ; do for test_name in $(ls "${TEST_BASEDIR}/regressiontests/" | grep ".*\.${test_ext}$") ; do run_test "regressiontests/${test_name}" "${CODES_SUCCESS}" "${CODES_SKIPPED}" "${CODES_FAILURE}" done + for test_name in $(ls "${TEST_BASEDIR}/regressiontests/sli2py_ignore/" | grep ".*\.${test_ext}$") ; do + run_test "regressiontests/sli2py_ignore/${test_name}" "${CODES_SUCCESS}" "${CODES_SKIPPED}" "${CODES_FAILURE}" + done done junit_close diff --git a/testsuite/regressiontests/sli2py_ignore/CMakeLists.txt b/testsuite/regressiontests/sli2py_ignore/CMakeLists.txt new file mode 100644 index 0000000000..edcf6d6729 --- /dev/null +++ b/testsuite/regressiontests/sli2py_ignore/CMakeLists.txt @@ -0,0 +1,28 @@ +# testsuite/regressiontests/sli2py_ignore/CMakeLists.txt +# +# This file is part of NEST. +# +# Copyright (C) 2004 The NEST Initiative +# +# NEST is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 2 of the License, or +# (at your option) any later version. +# +# NEST 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 General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with NEST. If not, see . + +# add regressiontests files +file( GLOB scripts RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} *.sli ) + +foreach( script ${scripts} ) + add_test( NAME regressiontests/sli2py_ignore/${script} + COMMAND ${CMAKE_INSTALL_FULL_BINDIR}/nest + ${CMAKE_INSTALL_FULL_DOCDIR}/regressiontests/sli2py_ignore/${script} # use the installed version + ) +endforeach() From b135a27d25360e1c6b25d4d31aa401995e4e596e Mon Sep 17 00:00:00 2001 From: Nicolai Haug Date: Fri, 2 Jun 2023 13:43:33 +0200 Subject: [PATCH 3/3] Remove mistakenly added loop --- testsuite/do_tests.sh | 4 ---- 1 file changed, 4 deletions(-) diff --git a/testsuite/do_tests.sh b/testsuite/do_tests.sh index 08b7205e31..35a3238597 100755 --- a/testsuite/do_tests.sh +++ b/testsuite/do_tests.sh @@ -339,10 +339,6 @@ for test_ext in ${tests_collect} ; do done done -for test_ext in ${tests_collect} ; do - -done - junit_close echo