3 # This program tests the BEGIN DATA / END DATA commands
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 export STAT_CONFIG_PATH=$top_srcdir/config
49 activity="create program"
50 cat > $TESTFILE << EOF_foobar
51 title 'Test BEGIN DATA ... END DATA'.
73 if [ $? -ne 0 ] ; then no_result ; fi
76 activity="run program"
77 $SUPERVISOR $here/../src/pspp -o raw-ascii $TESTFILE
78 if [ $? -ne 0 ] ; then no_result ; fi
80 activity="compare data"
81 diff -b -B $TEMPDIR/pspp.list - << foobar
82 1.1 DATA LIST. Reading 1 record from the command file.
83 +--------+------+-------+------+
84 |Variable|Record|Columns|Format|
85 #========#======#=======#======#
88 +--------+------+-------+------+
98 2.1 DATA LIST. Reading 1 record from the command file.
99 +--------+------+-------+------+
100 |Variable|Record|Columns|Format|
101 #========#======#=======#======#
104 +--------+------+-------+------+
114 if [ $? -ne 0 ] ; then fail ; fi