TEMPDIR=/tmp/pspp-tst-$$
-here=`pwd`;
-
-# ensure that top_srcdir is absolute
-cd $top_srcdir; top_srcdir=`pwd`
+# ensure that top_srcdir and top_builddir are absolute
+if [ -z "$top_srcdir" ] ; then top_srcdir=. ; fi
+if [ -z "$top_builddir" ] ; then top_builddir=. ; fi
+top_srcdir=`cd $top_srcdir; pwd`
+top_builddir=`cd $top_builddir; pwd`
+PSPP=$top_builddir/src/ui/terminal/pspp
STAT_CONFIG_PATH=$top_srcdir/config
export STAT_CONFIG_PATH
+LANG=C
+export LANG
+
cleanup()
{
if [ $? -ne 0 ] ; then no_result ; fi
activity="run program"
-$SUPERVISOR $here/../src/pspp -o raw-ascii $TEMPDIR/vectors.stat > $TEMPDIR/vectors.err 2> $TEMPDIR/vectors.out
+$SUPERVISOR $PSPP -o raw-ascii $TEMPDIR/vectors.stat > $TEMPDIR/vectors.err 2> $TEMPDIR/vectors.out
if [ $? -ne 0 ] ; then fail ; fi
activity="compare results"
-perl -pi -e s/^\s*\$//g $TEMPDIR/pspp.list
-diff -b $TEMPDIR/pspp.list - <<EOF | perl -e 's/^\s*$//g'
-1.1 DATA LIST. Reading 1 record from the command file.
+perl -pi -e 's/^\s*$//g' $TEMPDIR/pspp.list
+diff -b $TEMPDIR/pspp.list - <<EOF
+1.1 DATA LIST. Reading 1 record from INLINE.
+--------+------+-------+------+
|Variable|Record|Columns|Format|
#========#======#=======#======#
|N4 | 1| 4- 4|F1.0 |
|N5 | 1| 5- 5|F1.0 |
+--------+------+-------+------+
-
N1 N2 N3 N4 N5 X1 X2 X3 X4 X5 I
-- -- -- -- -- -- -- -- -- -- --
1 2 3 4 5 . 3 . . . 5