Updating ncgen run_nc4_tests.sh script to ensure that results are tested in addition to whether or not ncgen exited successfully.

This commit is contained in:
Ward Fisher 2016-11-16 11:09:14 -07:00
parent a845b92394
commit bc6fc8ac14
3 changed files with 15 additions and 5 deletions

View File

@ -35,7 +35,8 @@ endif # USE_NETCDF4
#endif # !BUILD_DLL
CLEANFILES = c0.nc c0_64.nc c0_4.nc c0_4c.nc ref_camrun.c \
ncf199.nc c5.nc compound_datasize_test.nc
ncf199.nc c5.nc compound_datasize_test.nc \
tst_compound_datasize_test.cdl tst_ncf199.cdl
# These rules are used if someone wants to rebuild ncgenl.c or ncgeny.c
# Otherwise never invoked, but records how to do it.

View File

@ -1,11 +1,13 @@
netcdf ncf199 {
dimensions:
F1 = 3 ;
R1 = UNLIMITED ;
R1 = UNLIMITED ; // (2 currently)
variables:
int fr(F1,R1);
data:
// This causes assertion violation:
// assertion failure: (dimindex < lastunlimited && (dimset->dimsyms[dimindex]->dim.isunlimited))
fr = {1,2}, {3,4}, {5,6} ;
fr =
{1,2},
{3,4},
{5,6} ;
}

View File

@ -18,9 +18,16 @@ echo "*** creating C code for CAM file ref_camrun.cdl..."
echo "*** test for jira NCF-199 bug"
./ncgen -k nc4 $srcdir/ncf199.cdl
../ncdump/ncdump ncf199.nc > tst_ncf199.cdl
echo "*** comparing binary against source file..."
diff -b -w $srcdir/ncf199.cdl tst_ncf199.cdl
echo "*** creating binary file for github issue 323..."
./ncgen -k nc4 $srcdir/compound_datasize_test.cdl
../ncdump/ncdump compound_datasize_test.nc > tst_compound_datasize_test.cdl
echo "*** comparing binary against source file..."
diff -b -w $srcdir/compound_datasize_test.cdl tst_compound_datasize_test.cdl
echo "*** Test successful!"
exit 0