Skip to content
This repository was archived by the owner on Mar 20, 2023. It is now read-only.

Commit 49bd200

Browse files
authored
Cleanup integration tests (#798)
The ring_different_seed test was not actually enabled, and in any case the ringtest is not sensitive to the Random123 seed.
1 parent 0b3b9e9 commit 49bd200

File tree

3 files changed

+17
-111
lines changed

3 files changed

+17
-111
lines changed

tests/integration/CMakeLists.txt

Lines changed: 14 additions & 44 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# =============================================================================
2-
# Copyright (c) 2016 - 2021 Blue Brain Project/EPFL
2+
# Copyright (c) 2016 - 2022 Blue Brain Project/EPFL
33
#
44
# See top-level LICENSE file for details.
55
# =============================================================================
@@ -59,48 +59,37 @@ endif()
5959

6060
# ~~~
6161
# As reports require MPI, do not add test if report is enabled.
62-
# GPU tests need SLURM allocation and hence they won't run without srun
6362
# ~~~
64-
if(NOT CORENRN_ENABLE_REPORTING AND NOT CORENRN_ENABLE_GPU)
63+
if(NOT CORENRN_ENABLE_REPORTING)
6564
list(
6665
APPEND
6766
TEST_CASES_WITH_ARGS
6867
"ring_serial!--tstop 100. --celsius 6.3 --datpath ${RING_DATASET_DIR} ${MODEL_STATS_ARG} --outpath ${CMAKE_CURRENT_BINARY_DIR}/ring_serial"
6968
)
7069
endif()
7170

72-
set(NEGATIVE_TEST_CASES_WITH_ARGS
73-
"ring_different_seed!${RING_COMMON_ARGS} ${GPU_ARGS} --outpath ${CMAKE_CURRENT_BINARY_DIR}/ring_different_seed --seed 123456"
74-
)
75-
7671
# ~~~
7772
# There are no directories for permute and multisend related tests,
7873
# create them and copy reference spikes
7974
# ~~~
8075
foreach(data_dir "ring" "ring_gap")
8176
foreach(
8277
test_suffix
83-
"serial"
84-
"multisend"
85-
"binqueue"
86-
"savestate_permute0"
87-
"savestate_permute1"
88-
"savestate_permute2"
89-
"permute1"
90-
"permute2"
91-
"permute2_cudaInterface")
78+
""
79+
"_serial"
80+
"_multisend"
81+
"_binqueue"
82+
"_savestate_permute0"
83+
"_savestate_permute1"
84+
"_savestate_permute2"
85+
"_permute1"
86+
"_permute2"
87+
"_permute2_cudaInterface")
9288
file(COPY "${CMAKE_CURRENT_SOURCE_DIR}/${data_dir}/out.dat.ref"
93-
DESTINATION "${CMAKE_CURRENT_BINARY_DIR}/${data_dir}_${test_suffix}/")
89+
DESTINATION "${CMAKE_CURRENT_BINARY_DIR}/${data_dir}${test_suffix}/")
9490
endforeach()
9591
endforeach()
96-
97-
# base tests : ring, ring with gap and ring duplication
98-
foreach(data_dir "ring" "ring_gap")
99-
file(COPY "${CMAKE_CURRENT_SOURCE_DIR}/${data_dir}/out.dat.ref"
100-
DESTINATION "${CMAKE_CURRENT_BINARY_DIR}/${data_dir}/")
101-
endforeach()
102-
103-
# test for small spike buffer
92+
# test without ring_gap version
10493
file(COPY "${CMAKE_CURRENT_SOURCE_DIR}/ring/out.dat.ref"
10594
DESTINATION "${CMAKE_CURRENT_BINARY_DIR}/ring_spike_buffer/")
10695

@@ -132,25 +121,6 @@ foreach(args_line ${TEST_CASES_WITH_ARGS})
132121
list(APPEND CORENRN_TEST_NAMES ${TEST_NAME}_TEST)
133122
endforeach()
134123

135-
foreach(args_line ${NEGATIVE_TEST_CASES})
136-
string(REPLACE "!" ";" string_line ${args_line})
137-
set(test_num_processors 1)
138-
if(MPI_FOUND)
139-
set(test_num_processors 2)
140-
string(REPLACE ";" " " SRUN_PREFIX "${TEST_MPI_EXEC_BIN};-n;${test_num_processors}")
141-
endif()
142-
list(GET string_line 0 TEST_NAME)
143-
list(GET string_line 1 TEST_ARGS)
144-
set(SIM_NAME ${TEST_NAME})
145-
configure_file(negative_integration_test.sh.in ${TEST_NAME}/negative_integration_test.sh @ONLY)
146-
add_test(
147-
NAME ${TEST_NAME}_TEST
148-
COMMAND "/bin/sh" ${CMAKE_CURRENT_BINARY_DIR}/${TEST_NAME}/negative_integration_test.sh
149-
WORKING_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/${TEST_NAME}")
150-
set_tests_properties(${TEST_NAME}_TEST PROPERTIES PROCESSORS ${test_num_processors})
151-
list(APPEND CORENRN_TEST_NAMES ${TEST_NAME}_TEST)
152-
endforeach()
153-
154124
if(CORENRN_ENABLE_REPORTING)
155125
foreach(TEST_NAME "1")
156126
set(SIM_NAME "reporting_${TEST_NAME}")

tests/integration/integration_test.sh.in

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
#! /bin/sh
1+
#!/usr/bin/env bash
2+
set -e
23

34
export OMP_NUM_THREADS=1
45
export LIBSONATA_ZERO_BASED_GIDS=true
@@ -49,7 +50,7 @@ then
4950
exit 1
5051
fi
5152

52-
diff -w out.dat out.dat.ref > diff.dat 2>&1
53+
diff -w out.dat out.dat.ref > diff.dat 2>&1 || true
5354

5455
if [ -s diff.dat ]
5556
then

tests/integration/negative_integration_test.sh.in

Lines changed: 0 additions & 65 deletions
This file was deleted.

0 commit comments

Comments
 (0)