mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-02-25 18:55:30 -06:00
Fix Damaris test.
The h5diff program returns 1 (failure) if there are any differences at all, even if using a relative or absolute difference tolerance and seeing no differences above the tolerance. In that situation, the output will be empty, but the return value 1. To make this test behave similar to the other regression tests, we now check if its output is empty instead. Also: set relative tolerance to 0.01 and remove the absolute test. This test is not meant to trigger for numerics changes, but should capture errors in the writing of the HDF5 file.
This commit is contained in:
parent
874b136ce9
commit
db1be5e92b
@ -449,7 +449,7 @@ if(MPI_FOUND)
|
||||
FILENAME SPE1CASE1
|
||||
SIMULATOR flow
|
||||
ABS_TOL ${abs_tol}
|
||||
REL_TOL ${rel_tol}
|
||||
REL_TOL 0.01
|
||||
DIR spe1)
|
||||
endif()
|
||||
|
||||
|
@ -52,9 +52,9 @@ do
|
||||
if test -f ${INPUT_DATA_PATH}/opm-simulation-reference/${EXE_NAME}/${fname}
|
||||
then
|
||||
echo -e "\t - ${fname}"
|
||||
${H5DIFF_COMMAND} -d ${ABS_TOL} ${INPUT_DATA_PATH}/opm-simulation-reference/${EXE_NAME}/${fname} ${RESULT_PATH}/${fname}
|
||||
test $? -eq 0 || exit 1
|
||||
${H5DIFF_COMMAND} -p ${REL_TOL} ${INPUT_DATA_PATH}/opm-simulation-reference/${EXE_NAME}/${fname} ${RESULT_PATH}/${fname}
|
||||
test $? -eq 0 || exit 1
|
||||
h5diffout=$(${H5DIFF_COMMAND} --relative=${REL_TOL} ${INPUT_DATA_PATH}/opm-simulation-reference/${EXE_NAME}/${fname} ${RESULT_PATH}/${fname})
|
||||
if [ -n "${h5diffout}" ]; then
|
||||
exit 1
|
||||
fi
|
||||
fi
|
||||
done
|
||||
|
Loading…
Reference in New Issue
Block a user