File: test-outputs

package info (click to toggle)
spline 1.2-1
  • links: PTS
  • area: main
  • in suites: jessie, jessie-kfreebsd, squeeze, wheezy
  • size: 136 kB
  • ctags: 57
  • sloc: ansic: 355; makefile: 132; sh: 32
file content (22 lines) | stat: -rwxr-xr-x 460 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#!/bin/sh

# Test whether points are duplicated in output as per bug #578004

TESTDATA=${1:-outputs.dat}
ASPLINE=${ASPLINE:-aspline}

for N in 0 11 20 21 30 31 35 40 41 60 61 100 101 110 111
do
  arg=
  if [ $N -gt 0 ]
  then
    arg="-n $N"
  fi
  N1=$($ASPLINE $arg $TESTDATA |        wc -l)
  N2=$($ASPLINE $arg $TESTDATA | uniq | wc -l)
  if [ $N1 -ne $N2 ]
  then
    echo "Got different numbers of points when filtering: $N $N1 $N2"
    exit 1
  fi
done