mirror of https://github.com/ecmwf/eccodes.git
ECC-1352: GRIB CCSDS packing: Add extra tests (Part 3)
This commit is contained in:
parent
6d909751a4
commit
4f752c4880
Binary file not shown.
|
@ -10,22 +10,28 @@
|
|||
|
||||
. ./include.sh
|
||||
|
||||
label="grib_ccsds_test"
|
||||
REDIRECT=/dev/null
|
||||
|
||||
# Disable if autotools being used
|
||||
src_config=${src_dir}/config.h
|
||||
if [ -f ${src_config} ]; then
|
||||
exit 0
|
||||
fi
|
||||
|
||||
BLACKLIST="totalLength,section5Length,section7Length,dataRepresentationTemplateNumber"
|
||||
|
||||
infile=${data_dir}/ccsds.grib2
|
||||
outfile1=$infile.tmp_ccsds.1
|
||||
outfile2=$infile.tmp_ccsds.2
|
||||
outfile1=temp.$label.1
|
||||
outfile2=temp.$label.2
|
||||
|
||||
rm -f $outfile1 $outfile2
|
||||
|
||||
# Use the sample file with CCSDS packing
|
||||
# ---------------------------------------
|
||||
sample_ccsds=$ECCODES_SAMPLES_PATH/ccsds_grib2.tmpl
|
||||
${tools_dir}/grib_filter -o $outfile1 - $sample_ccsds << EOF
|
||||
set values = { 55.0161, 99.7008 };
|
||||
write;
|
||||
EOF
|
||||
grib_check_key_equals $outfile1 packingType grid_ccsds
|
||||
stats=`${tools_dir}/grib_get -M -F%.4f -p min,max $outfile1`
|
||||
[ "$stats" = "55.0161 99.7008" ]
|
||||
|
||||
# ECC-1263
|
||||
# ---------
|
||||
grib2_sample=$ECCODES_SAMPLES_PATH/gg_sfc_grib2.tmpl
|
||||
|
|
Loading…
Reference in New Issue