source: git/tests/diffpos.tst@ b6de07d

RELEASE/1.0 RELEASE/1.1 RELEASE/1.2 debug-ci debug-ci-sanitisers faster-cavernlog log-select main stereo stereo-2025 walls-data walls-data-hanging-as-warning warn-only-for-hanging-survey
Last change on this file since b6de07d was 4d3dfdf, checked in by Olly Betts <olly@…>, 25 years ago

Fixed --survey filtering in img.c and added testcase to diffpos.tst

git-svn-id: file:///home/survex-svn/survex/trunk@1707 4b37db11-9a0c-4f06-9ece-9ab7cdaee568

  • Property mode set to 100755
File size: 1.0 KB
Line 
1#!/bin/sh
2
3testdir=`echo $0 | sed 's!/[^/]*$!!' || echo '.'`
4
5# allow us to run tests standalone more easily
6: ${srcdir="$testdir"}
7
8# force VERBOSE if we're run on a subset of tests
9test -n "$*" && VERBOSE=1
10
11test -x "$testdir"/../src/cavern || testdir=.
12
13: ${DIFFPOS="$testdir"/../src/diffpos}
14
15SURVEXHOME="$srcdir"/../lib
16export SURVEXHOME
17
18: ${TESTS=${*-"delatend addatend"}}
19
20for file in $TESTS ; do
21 echo $file
22 rm -f diffpos.tmp
23 $DIFFPOS $srcdir/${file}a.pos $srcdir/${file}b.pos > diffpos.tmp
24 if test -n "$VERBOSE" ; then
25 cat diffpos.tmp
26 cmp diffpos.tmp $srcdir/${file}.out || exit 1
27 else
28 cmp diffpos.tmp $srcdir/${file}.out > /dev/null || exit 1
29 fi
30 rm -f diffpos.tmp
31done
32
33for args in '' '--survey survey' '--survey survey.xyzzy' '--survey xyzzy' ; do
34 echo "diffpos $args"
35 rm -f diffpos.tmp
36 $DIFFPOS $args $srcdir/v0.3d $srcdir/v0.3d > diffpos.tmp
37 if test -n "$VERBOSE" ; then
38 cat diffpos.tmp
39 fi
40 cmp diffpos.tmp /dev/null > /dev/null || exit 1
41 rm -f diffpos.tmp
42done
43
44exit 0
Note: See TracBrowser for help on using the repository browser.