mirror of https://github.com/ecmwf/eccodes.git
Testing: Add test for ECC-1028 (incorrect replication)
This commit is contained in:
parent
83411cf856
commit
c6ffb8121f
|
@ -84,6 +84,7 @@ if( HAVE_BUILD_TOOLS )
|
|||
grib_ecc-1195
|
||||
grib_ecc-1212
|
||||
grib_ecc-1230
|
||||
bufr_ecc-1028
|
||||
bufr_ecc-1195
|
||||
bufr_json_samples
|
||||
bufr_ecc-359
|
||||
|
|
|
@ -0,0 +1,30 @@
|
|||
#!/bin/sh
|
||||
# (C) Copyright 2005- ECMWF.
|
||||
#
|
||||
# This software is licensed under the terms of the Apache Licence Version 2.0
|
||||
# which can be obtained at http://www.apache.org/licenses/LICENSE-2.0.
|
||||
#
|
||||
# In applying this licence, ECMWF does not waive the privileges and immunities granted to it by
|
||||
# virtue of its status as an intergovernmental organisation nor does it submit to any jurisdiction.
|
||||
#
|
||||
|
||||
. ./include.sh
|
||||
set -u
|
||||
label="bufr_ecc-1028_test"
|
||||
tempFilter=temp.$label.filt
|
||||
tempError=temp.$label.err
|
||||
|
||||
sample_bufr4=$ECCODES_SAMPLES_PATH/BUFR4.tmpl
|
||||
|
||||
# Incorrect replication. Encoding should fail
|
||||
echo "set unexpandedDescriptors={ 101000, 31002 }; write;" > $tempFilter
|
||||
set +e
|
||||
${tools_dir}/bufr_filter $tempFilter $sample_bufr4 2>$tempError
|
||||
status=$?
|
||||
set -e
|
||||
[ $status -ne 0 ]
|
||||
# Check error message
|
||||
grep -q "Delayed replication: 101000: expected 1 but only found 0 elements" $tempError
|
||||
|
||||
|
||||
rm -f $tempFilter $tempError
|
Loading…
Reference in New Issue