File: maintest

package info (click to toggle)
graywolf 0.1.6-4
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, bullseye
  • size: 6,424 kB
  • sloc: ansic: 84,358; sh: 216; awk: 36; makefile: 22
file content (53 lines) | stat: -rwxr-xr-x 952 bytes parent folder | download | duplicates (2)
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
49
50
51
52
53
#!/bin/bash

#set -e

TMPDIR=`mktemp -d`

cp tests/map9v3/map9v3.cel ${TMPDIR}/
cp tests/map9v3/map9v3.par ${TMPDIR}/

RET=0

pushd ${TMPDIR}
graywolf -n map9v3 2> stderr.log
RETRUN="$?"
popd

if [ "$RETRUN" != "0" ] ; then
  RET=1
fi

if [ ! -f ${TMPDIR}/map9v3.pl1 ] ; then
  echo "map9v3.pl1 not found after running graywolf"
  RET=1
fi


# Not reliable since different on 64bit vs 32bit architetures
#diff ${TMPDIR}/map9v3.pl1 tests/map9v3/expected/map9v3.pl1
#RETSUB="$?"
#if [ "$RETSUB" != "0" ] ; then
#  RET=1
#fi

if [ ! -f ${TMPDIR}/map9v3.pl2 ] ; then
  echo "map9v3.pl2 not found after running graywolf"
  RET=1
fi

# Not reliable since different on 64bit vs 32bit architetures
#diff ${TMPDIR}/map9v3.pl2 tests/map9v3/expected/map9v3.pl2
#RETSUB="$?"
#if [ "$RETSUB" != "0" ] ; then
#  RET=1
#fi

if [ "$RET" != "0" ] ; then
  echo "stderr from running graywolf -->"
  cat ${TMPDIR}/stderr.log
  echo "<--"
fi

rm -rf ${TMPDIR}
exit ${RET}