3 # This program tests the LAG function
5 TEMPDIR=/tmp/pspp-tst-$$
6 TESTFILE=$TEMPDIR/`basename $0`.sps
10 # ensure that top_srcdir is absolute
11 cd $top_srcdir; top_srcdir=`pwd`
13 STAT_CONFIG_PATH=$top_srcdir/config
14 export STAT_CONFIG_PATH
50 activity="create program"
51 cat > $TEMPDIR/lag.stat <<EOF
66 if [ $? -ne 0 ] ; then no_result ; fi
68 activity="run program"
69 $SUPERVISOR $here/../src/pspp -o raw-ascii $TEMPDIR/lag.stat
70 if [ $? -ne 0 ] ; then no_result ; fi
72 activity="compare result"
73 diff -b -B $TEMPDIR/pspp.list - <<EOF
74 1.1 DATA LIST. Reading 1 record from the command file.
75 +--------+------+-------+------+
76 |Variable|Record|Columns|Format|
77 #========#======#=======#======#
79 +--------+------+-------+------+
82 - -------- -------- --------
89 if [ $? -ne 0 ] ; then fail ; fi