eccodes/tests/grib_ecc-967.sh

30 lines
1.1 KiB
Bash
Raw Permalink Normal View History

2019-08-07 17:32:18 +00:00
#!/bin/sh
2020-01-28 14:32:34 +00:00
# (C) Copyright 2005- ECMWF.
2019-08-07 17:32:18 +00:00
#
# 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.ctest.sh
2022-06-06 14:41:18 +00:00
2019-08-07 17:32:18 +00:00
# ---------------------------------------------------------
# This is the test for the JIRA issue ECC-967.
# GRIB2: Fallback if tables version > latest installed version
# ---------------------------------------------------------
2022-06-06 14:41:18 +00:00
label="grib_ecc-967_test"
2019-08-07 17:32:18 +00:00
temp=temp.${label}.grib
2023-08-16 17:16:51 +00:00
# Pick a master tables version number way too big!
2019-08-07 17:32:18 +00:00
# But one day we will actually get to it.
input=$ECCODES_SAMPLES_PATH/reduced_gg_pl_160_grib2.tmpl
${tools_dir}/grib_set -s tablesVersion=253 $input $temp
grib_check_key_equals $temp 'typeOfFirstFixedSurface:i' '100'
grib_check_key_equals $temp 'typeOfFirstFixedSurface:s' 'pl'
grib_check_key_equals $temp 'mars.levtype' 'pl'
# Clean up
rm -f $temp