X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=tests%2Fcommand%2Ffile-label.sh;h=37d3fb806c34d8b8e710f98abf5b7b014282e784;hb=053e7ff6e0a45a25d5604b211e9c950fff50e75d;hp=f69e79d28a8f6ebd021573ccfa7a90d151e83411;hpb=c0ed03fd27298cf2b18f0fb373e919ab8b4ae4f4;p=pspp diff --git a/tests/command/file-label.sh b/tests/command/file-label.sh index f69e79d28a..37d3fb806c 100755 --- a/tests/command/file-label.sh +++ b/tests/command/file-label.sh @@ -3,17 +3,20 @@ # This program tests the FILE LABEL and DOCUMENT commands TEMPDIR=/tmp/pspp-tst-$$ +TESTFILE=$TEMPDIR/`basename $0`.sps here=`pwd`; # ensure that top_srcdir is absolute cd $top_srcdir; top_srcdir=`pwd` -export STAT_CONFIG_PATH=$top_srcdir/config +STAT_CONFIG_PATH=$top_srcdir/config +export STAT_CONFIG_PATH cleanup() { + cd / rm -rf $TEMPDIR } @@ -46,11 +49,10 @@ mkdir -p $TEMPDIR cd $TEMPDIR activity="create program" -cat > $TEMPDIR/file-lab.stat << EOF - +cat > $TESTFILE << EOF /* Set up a dummy active file in memory. -data list /x 1 y 2. +data list /X 1 Y 2. begin data. 16 27 @@ -74,8 +76,8 @@ display documents. display file label. /* undocumented feature of PSPP /* Save the active file then get it and display the documents again. -save 'foo.save'. -get 'foo.save'. +save /OUTFILE='foo.save'. +get /FILE='foo.save'. display documents. display file label. /* undocumented feature of PSPP @@ -93,8 +95,8 @@ document There should be another document now. display documents. /* Save and get. -save 'foo.save'. -get 'foo.save'. +save /OUTFILE='foo.save'. +get /FILE='foo.save'. display documents. display file label. /* undocumented feature of PSPP @@ -104,7 +106,7 @@ EOF if [ $? -ne 0 ] ; then no_result ; fi activity="run program" -$here/../src/pspp --testing-mode -o raw-ascii $TEMPDIR/file-lab.stat +$SUPERVISOR $here/../src/pspp --testing-mode -o raw-ascii $TESTFILE if [ $? -ne 0 ] ; then no_result ; fi # We need to filter out the dates/times @@ -114,49 +116,37 @@ if [ $? -ne 0 ] ; then no_result ; fi activity="compare results" -diff -b -B $TEMPDIR/pspp.filtered - <