3 # This program tests for a bug which caused a crash when
4 # very large files are presented.
7 TEMPDIR=/tmp/pspp-tst-$$
8 TESTFILE=$TEMPDIR/`basename $0`.sps
12 # ensure that top_srcdir is absolute
13 cd $top_srcdir; top_srcdir=`pwd`
15 export STAT_CONFIG_PATH=$top_srcdir/config
51 activity="delete data"
52 rm -f $TEMPDIR/large.dat
53 if [ $? -ne 0 ] ; then no_result ; fi
55 printf "Creating input data. Please wait"
56 activity="create data"
59 done ) | head -100000 >> $TEMPDIR/large.dat
60 if [ $? -ne 0 ] ; then no_result ; fi
64 done ) | head -100000 >> $TEMPDIR/large.dat
65 if [ $? -ne 0 ] ; then no_result ; fi
68 activity="create program"
70 DATA LIST FILE='$TEMPDIR/large.dat' /S 1-2 (A) X 3 .
73 AGGREGATE /BREAK=X /A=N.
78 if [ $? -ne 0 ] ; then no_result ; fi
80 activity="run program"
81 $SUPERVISOR $here/../src/pspp -o raw-ascii $TESTFILE > /dev/null
82 if [ $? -ne 0 ] ; then fail ; fi
84 activity="appending to data"
85 # Put another 100,000 cases into large.dat
89 done ) | head -50000 >> $TEMPDIR/large.dat
90 if [ $? -ne 0 ] ; then no_result ; fi
92 activity="run program"
93 $SUPERVISOR $here/../src/pspp -o raw-ascii $TESTFILE > /dev/null
94 if [ $? -ne 0 ] ; then fail ; fi