Add scratch file handles.
[pspp-builds.git] / tests / command / t-test-1s.sh
index 382a9b1f9922248cee2baa21908c3a9e230061a7..4120e05551f6c90cf68db5d324a00725e6858f5d 100755 (executable)
@@ -10,11 +10,13 @@ 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
 }
 
@@ -48,7 +50,7 @@ cd $TEMPDIR
 
 activity="create program"
 cat > $TESTFILE <<EOF
-data list list /id * abc *.
+data list list /ID * ABC *.
 begin data.
 1 3.5
 2 2.0
@@ -68,22 +70,21 @@ $SUPERVISOR $here/../src/pspp -o raw-ascii $TESTFILE
 if [ $? -ne 0 ] ; then no_result ; fi
 
 activity="compare output"
-diff -B -b $TEMPDIR/pspp.list - <<EOF
-1.1 DATA LIST.  Reading free-form data from the command file.
+perl -pi -e 's/^\s*$//g' $TEMPDIR/pspp.list
+diff  -b $TEMPDIR/pspp.list - <<EOF
+1.1 DATA LIST.  Reading free-form data from INLINE.
 +--------+------+
 |Variable|Format|
 #========#======#
 |ID      |F8.0  |
 |ABC     |F8.0  |
 +--------+------+
-
 2.1 T-TEST.  One-Sample Statistics
 #===#=#====#==============#========#
 #   #N|Mean|Std. Deviation|SE. Mean#
 #===#=#====#==============#========#
 #ABC#6|3.00|           .84|    .342#
 #===#=#====#==============#========#
-
 2.2 T-TEST.  One-Sample Test
 #===#=====================================================#
 #   #                Test Value = 2.000000                #