Debian Codegraph @

texk/dvidvi/dvidvi.test

raw
1 #! /bin/sh -vx
2 # $Id: dvidvi.test 68031 2023-08-23 14:53:12Z takuji $
3 # Copyright 2017-2021 Karl Berry <[email protected]>
4 # Copyright 2011 Peter Breitenlohner <[email protected]>
5 # You may freely use, modify and/or distribute this file.
6
7 BinDir=${BinDir:-.}
8 ExeExt=${ExeExt:-}
9 _dvidvi=$BinDir/dvidvi$ExeExt
10
11 # pre-generated test results in the repository are stored in LF
12 # but the output might be written in CRLF on some platform.
13 # if 'diff --strip-trailing-cr' is available, exploit it.
14 # (useful for tests on win32 binaries run on MSYS shell)
15 DIFF="diff"
16 $DIFF --strip-trailing-cr $0 $0 \
17 && DIFF="diff --strip-trailing-cr" || echo
18
19 TEXMFCNF=$srcdir/../kpathsea; export TEXMFCNF
20
21 rm -rf play*
22 cp $srcdir/tests/play.dvi .
23 $_dvidvi -f 5 -l @25 -m'4:-3,0(6,0)' play playout 2>playout.2
24 #
25 # Eliminate version number for the comparison.
26 grep -v '^This is dvidvi' playout.2 \
27 | $DIFF - $srcdir/tests/playout.2 \
28 || exit 1
29
30 rm -rf play*
31 cp $srcdir/tests/playtate.dvi .
32 $_dvidvi -f 5 -l @25 -m'4:-3,0(6,0)' playtate playout 2>playout.3
33 #
34 grep -v '^This is dvidvi' playout.3 \
35 | $DIFF - $srcdir/tests/playout.3 \
36 || exit 2
37
38 exit 0