This commit is contained in:
Shahram Najm 2018-07-12 16:17:05 +01:00
parent 55c31f5879
commit 4bad2a95c6
2 changed files with 12 additions and 4 deletions

View File

@ -9,7 +9,7 @@
*/
#include "grib_api.h"
#include <assert.h>
/*
* Test FA conversion to grib_api
* philippe.marguinaud@meteo.fr 02/2016
@ -847,6 +847,10 @@ int main (int argc, char * argv[])
{
grib_handle* h = NULL;
size_t len = 0;
const char* outfile;
assert(argc==2);
outfile = argv[1];
GRIB_CHECK (((h = grib_handle_new_from_samples (NULL, "regular_ll_pl_grib2")) == NULL), 0);
/*GRIB_CHECK (((h = grib_handle_new_from_samples (NULL, "reduced_gg_ml_grib2")) == NULL), 0);*/
@ -905,7 +909,7 @@ int main (int argc, char * argv[])
GRIB_CHECK (grib_set_long (h, "LLCOSP", 0), 0);
GRIB_CHECK (grib_set_long (h, "INBITS", 16), 0);
GRIB_CHECK(grib_write_message(h, "output.local_MeteoFrance.grib", "w"), 0);
GRIB_CHECK(grib_write_message(h, outfile, "w"), 0);
GRIB_CHECK (grib_handle_delete (h), 0);

View File

@ -10,5 +10,9 @@
. ./include.sh
${test_dir}/local_MeteoFrance
rm -f output.local_MeteoFrance.grib
TEMP=output.local_MeteoFrance.grib
${test_dir}/local_MeteoFrance $TEMP
grib_check_key_equals $TEMP "CLNOMA,INGRIB,INBITS" "SURFTEMPERATURE 120 16"
rm -f $TEMP