mirror of https://github.com/ecmwf/eccodes.git
Tests: make ref files optional
This commit is contained in:
parent
e1a39939da
commit
e8e7365a5c
|
@ -25,15 +25,14 @@ do
|
|||
# Test descriptors: compare output of filter (res) with reference file (ref)
|
||||
res_desc=$file.desc.test
|
||||
ref_desc=$file.desc.ref
|
||||
[ -f "$ref_desc" ]
|
||||
diff_desc=$file.desc.diff
|
||||
|
||||
rm -f $res_desc
|
||||
|
||||
${tools_dir}bufr_filter bufrdc_desc_ref.filter $file 2> $REDIRECT > $res_desc
|
||||
|
||||
if [ -f "$ref_desc" ]; then
|
||||
diff $ref_desc $res_desc > $diff_desc 2> $diff_desc
|
||||
|
||||
fi
|
||||
rm -f $res_desc $diff_desc
|
||||
done
|
||||
|
||||
|
|
|
@ -30,9 +30,11 @@ do
|
|||
|
||||
${tools_dir}bufr_filter bufrdc_num_ref.filter $file 2> $REDIRECT > $res_num
|
||||
|
||||
if [ -f "$ref_num" ]; then
|
||||
# Cannot use plain diff. We need to compare FLOAT NUMBERS with a tolerance
|
||||
perl number_compare.pl $ref_num $res_num >$REDIRECT 2> $REDIRECT
|
||||
#numdiff $ref_num $res_num >$REDIRECT 2> $REDIRECT
|
||||
fi
|
||||
|
||||
done
|
||||
|
||||
|
|
Loading…
Reference in New Issue