File: test_hyrax.sh

package info (click to toggle)
netcdf 1:4.7.4-1
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, sid
  • size: 104,952 kB
  • sloc: ansic: 228,683; sh: 10,980; yacc: 2,561; makefile: 1,319; lex: 1,173; xml: 173; awk: 2
file content (48 lines) | stat: -rwxr-xr-x 1,014 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
#!/bin/sh

if test "x$srcdir" = "x"; then srcdir=`dirname $0`; fi
export srcdir;

. ${srcdir}/../test_common.sh

FRAG="#checksummode=ignore"

F="\
nc4_nc_classic_comp.nc \
nc4_nc_classic_no_comp.nc \
nc4_strings.nc \
nc4_strings_comp.nc \
nc4_unsigned_types.nc \
nc4_unsigned_types_comp.nc \
ref_tst_compounds.nc \
"

failure() {
      echo "*** Fail: $1"
      exit 1
}

setresultdir results_test_hyrax

if test "x${RESET}" = x1 ; then rm -fr ${BASELINEH}/*.dmp ; fi
for f in $F ; do
    URL="dap4://test.opendap.org:8080/opendap/nc4_test_files/${f}${FRAG}"
    echo "testing: $URL"
    if ! ${NCDUMP} "${URL}" > ./results_test_hyrax/${f}.hyrax; then
        failure "${URL}"
    fi
    if test "x${TEST}" = x1 ; then
	if ! diff -wBb ${BASELINEREM}/${f}.hyrax ./results_test_hyrax/${f}.hyrax ; then
	    failure "diff ${f}.hyrax"
	fi
    elif test "x${RESET}" = x1 ; then
	echo "${f}:" 
	cp ./results_test_hyrax/${f}.hyrax ${BASELINEH}/${f}.hyrax
    fi
done

rm -rf ./results_test_hyrax

echo "*** Pass"
exit 0