Made tests BSD diff compatible
authorJason Stover <jhs@math.gcsu.edu>
Mon, 10 Oct 2005 20:49:13 +0000 (20:49 +0000)
committerJason Stover <jhs@math.gcsu.edu>
Mon, 10 Oct 2005 20:49:13 +0000 (20:49 +0000)
28 files changed:
tests/command/count.sh
tests/command/data-list.sh
tests/command/examine-extremes.sh
tests/command/examine-percentiles.sh
tests/command/examine.sh
tests/command/file-label.sh
tests/command/filter.sh
tests/command/flip.sh
tests/command/import-export.sh
tests/command/lag.sh
tests/command/list.sh
tests/command/longvars.sh
tests/command/loop.sh
tests/command/oneway-with-splits.sh
tests/command/oneway.sh
tests/command/print.sh
tests/command/rename.sh
tests/command/split-file.sh
tests/command/sysfiles-old.sh
tests/command/sysfiles.sh
tests/command/t-test-1-indep-val.sh
tests/command/t-test-1s.sh
tests/command/t-test-groups.sh
tests/command/t-test-pairs.sh
tests/command/tabs.sh
tests/command/trimmed-mean.sh
tests/command/use.sh
tests/command/weight.sh

index 0b5b751e09f66bc6069c9d894071b876445a7180..351d636fdef0b5ede2ef5e0f658a082d11bd7422 100755 (executable)
@@ -73,7 +73,8 @@ if [ $? -ne 0 ] ; then no_result ; fi
 
 
 activity="compare results"
-diff -b -B $TEMPDIR/pspp.list - <<EOF
+perl -pi -e s/^\s*\$//g $TEMPDIR/pspp.list
+diff -b  $TEMPDIR/pspp.list - <<EOF | perl -e 's/^\s*$//g'
 1.1 DATA LIST.  Reading 1 record from the command file.
 +--------+------+-------+------+
 |Variable|Record|Columns|Format|
index 4206e498a98d7e5ddce09b33088e53f8bf0f57ba..99b94aa5b15e7829a1069421b5654f873d7d9565 100755 (executable)
@@ -106,7 +106,8 @@ $SUPERVISOR $here/../src/pspp --testing-mode -o raw-ascii --testing-mode $TESTFI
 if [ $? -ne 0 ] ; then fail ; fi
 
 activity="compare output"
-diff -b -B $TEMPDIR/pspp.list - << EOF
+perl -pi -e s/^\s*\$//g $TEMPDIR/pspp.list
+diff -b  $TEMPDIR/pspp.list - << EOF | perl -e 's/^\s*$//g'
 1.1 DATA LIST.  Reading free-form data from the command file.
 +--------+------+
 |Variable|Format|
index b10fdbca5afc0fa8821f0f296eb4da4e896dc4bd..afecfa56cd7e57cad414ecd4935d0d23ac3c1e34 100755 (executable)
@@ -89,7 +89,8 @@ $SUPERVISOR $here/../src/pspp -o raw-ascii $TESTFILE
 if [ $? -ne 0 ] ; then no_result ; fi
 
 activity="compare results"
-diff -b -B $TEMPDIR/pspp.list - << EOF
+perl -pi -e s/^\s*\$//g $TEMPDIR/pspp.list
+diff -b  $TEMPDIR/pspp.list - << EOF | perl -e 's/^\s*$//g'
 1.1 EXAMINE.  Case Processing Summary
 #==#===============================#
 #  #             Cases             #
index 0d23b41feb03334f7f7c6194c9f4eb09ac55d024..21b88a04b942a666c13f34259238030250357dc3 100755 (executable)
@@ -82,7 +82,8 @@ if [ $? -ne 0 ] ; then no_result ; fi
 
 
 activity="compare results"
-diff -b -B $TEMPDIR/pspp.list - << EOF
+perl -pi -e s/^\s*\$//g $TEMPDIR/pspp.list
+diff -b  $TEMPDIR/pspp.list - << EOF | perl -e 's/^\s*$//g'
 1.1 DATA LIST.  Reading free-form data from the command file.
 +--------+------+
 |Variable|Format|
index 445e1dfc2b75e96be5519258be26d60eb1df7972..1136267f8c2c141393b0697ef161af5ae1d0e73d 100755 (executable)
@@ -94,7 +94,8 @@ if [ $? -ne 0 ] ; then no_result ; fi
 # NOTE:  In the following data: Only the extreme values have been checked
 # The descriptives have been blindly pasted.
 activity="compare results"
-diff -b -B $TEMPDIR/pspp.list - << EOF
+perl -pi -e s/^\s*\$//g $TEMPDIR/pspp.list
+diff -b  $TEMPDIR/pspp.list - << EOF | perl -e 's/^\s*$//g'
 1.1 DATA LIST.  Reading free-form data from the command file.
 +--------+------+
 |Variable|Format|
index aaf404f412d9991e2b76354de3bbdd33a8b76473..839990944250d67f133beb652dce4e3f9e2b92d7 100755 (executable)
@@ -116,7 +116,8 @@ if [ $? -ne 0 ] ; then no_result ; fi
 
 
 activity="compare results"
-diff -b -B $TEMPDIR/pspp.filtered - <<EOF
+perl -pi -e s/^\s*\$//g $TEMPDIR/pspp.list
+diff -b  $TEMPDIR/pspp.filtered - <<EOF | perl -e 's/^\s*$//g'
 1.1 DATA LIST.  Reading 1 record from the command file.
 +--------+------+-------+------+
 |Variable|Record|Columns|Format|
index 4e9559135197a89deac79a169ed1fa5c2d6d6a1f..b6ab48f046e202f58522152443873e1c5e3fa6ea 100755 (executable)
@@ -83,7 +83,8 @@ if [ $? -ne 0 ] ; then no_result ; fi
 
 
 activity="check results"
-diff -B -b $TEMPDIR/pspp.list - << EOF
+perl -pi -e s/^\s*\$//g $TEMPDIR/pspp.list
+diff  -b $TEMPDIR/pspp.list - << EOF | perl -e 's/^\s*$//g'
  X FILTER_$
 -- --------
  1     1.00 
index 60de8395cc1f3e7f42bd086d5c23bf47a6785426..f4eb926fefd916dc47f4819a00efab8af8a11904 100755 (executable)
@@ -72,7 +72,8 @@ $SUPERVISOR $here/../src/pspp -o raw-ascii $TEMPDIR/flip.stat
 if [ $? -ne 0 ] ; then no_result ; fi
 
 activity="compare output"
-diff  -b -B $TEMPDIR/pspp.list - << EOF
+perl -pi -e s/^\s*\$//g $TEMPDIR/pspp.list
+diff  -b  $TEMPDIR/pspp.list - << EOF | perl -e 's/^\s*$//g'
 1.1 DATA LIST.  Reading 1 record from the command file.
 +--------+------+-------+------+
 |Variable|Record|Columns|Format|
index 74a27543401bf6e61c24865ef530aedf6f512006..de8a147d558c0ef9b46860c4cf6ff74959468b0a 100755 (executable)
@@ -70,7 +70,8 @@ $SUPERVISOR $here/../src/pspp --testing-mode -o raw-ascii $TESTFILE
 if [ $? -ne 0 ] ; then no_result ; fi
 
 activity="compare output"
-diff -b -B $TEMPDIR/pspp.list - << EOF
+perl -pi -e s/^\s*\$//g $TEMPDIR/pspp.list
+diff -b  $TEMPDIR/pspp.list - << EOF | perl -e 's/^\s*$//g'
        X        Y
 -------- --------
     1.00     2.00 
index 579fd5af8c297506e503485d47f7c9b87aba4c9d..70d46e95606540c9a98cea51df1c319cbd8a315d 100755 (executable)
@@ -71,7 +71,8 @@ $SUPERVISOR $here/../src/pspp -o raw-ascii $TEMPDIR/lag.stat
 if [ $? -ne 0 ] ; then no_result ; fi
 
 activity="compare result"
-diff -b -B $TEMPDIR/pspp.list - <<EOF
+perl -pi -e s/^\s*\$//g $TEMPDIR/pspp.list
+diff -b  $TEMPDIR/pspp.list - <<EOF | perl -e 's/^\s*$//g'
 1.1 DATA LIST.  Reading 1 record from the command file.
 +--------+------+-------+------+
 |Variable|Record|Columns|Format|
index 13801abcbe42d256e2debfed94c8aad7151519ce..58098ebfe67235e8b1001d1e0a99f5f5abb7329c 100755 (executable)
@@ -73,7 +73,8 @@ if [ $? -ne 0 ] ; then no_result ; fi
 
 
 activity="compare results"
-diff -b -B $TEMPDIR/pspp.list - <<EOF
+perl -pi -e s/^\s*\$//g $TEMPDIR/pspp.list
+diff -b  $TEMPDIR/pspp.list - <<EOF | perl -e 's/^\s*$//g'
 1.1 DATA LIST.  Reading 1 record from file $top_srcdir/tests/weighting.data.
 +--------+------+-------+------+
 |Variable|Record|Columns|Format|
index 063ad6bb82df935324c124bb1170f0f5f3430f7b..8571ab5b71a0392897b048f2a1e2de659a0a6701 100755 (executable)
@@ -71,7 +71,8 @@ $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
+perl -pi -e s/^\s*\$//g $TEMPDIR/pspp.list
+diff  -b $TEMPDIR/pspp.list - <<EOF | perl -e 's/^\s*$//g'
 1.1 DATA LIST.  Reading free-form data from the command file.
 +--------------+------+
 |   Variable   |Format|
index f06f61a8a72123095369ff94168d7009e239d8ea..f5bfc92a5707d7d10273b7a9b627908e54ab48db 100755 (executable)
@@ -76,7 +76,8 @@ EOF
 if [ $? -ne 0 ] ; then fail ; fi
 
 activity="compare results"
-diff -B -b $TEMPDIR/pspp.list  - <<EOF
+perl -pi -e s/^\s*\$//g $TEMPDIR/pspp.list
+diff  -b $TEMPDIR/pspp.list  - <<EOF | perl -e 's/^\s*$//g'
 1.1 DATA LIST.  Reading 1 record from the command file.
 +----------+------+-------+------+
 | Variable |Record|Columns|Format|
index 333c66b321fbfd946612ff2e215a43d9eb2f946d..4de772137164eeb28a4edb45bdcb55a37af2c160 100755 (executable)
@@ -95,7 +95,8 @@ activity="run program"
 $SUPERVISOR $here/../src/pspp -o raw-ascii $TESTFILE
 if [ $? -ne 0 ] ; then no_result ; fi
 
-diff -b -B $TEMPDIR/pspp.list - << EOF
+perl -pi -e s/^\s*\$//g $TEMPDIR/pspp.list
+diff -b  $TEMPDIR/pspp.list - << EOF | perl -e 's/^\s*$//g'
 1.1 DATA LIST.  Reading free-form data from the command file.
 +--------+------+
 |Variable|Format|
index 91a72af6a7556f5277901ca247ee68f8832cee53..5de916748dcc3df0e52af83a40d54e083ffc5d02 100755 (executable)
@@ -92,7 +92,8 @@ activity="run program"
 $SUPERVISOR $here/../src/pspp -o raw-ascii $TESTFILE
 if [ $? -ne 0 ] ; then no_result ; fi
 
-diff -b -B $TEMPDIR/pspp.list - << EOF
+perl -pi -e s/^\s*\$//g $TEMPDIR/pspp.list
+diff -b  $TEMPDIR/pspp.list - << EOF | perl -e 's/^\s*$//g'
 1.1 DATA LIST.  Reading free-form data from the command file.
 +--------+------+
 |Variable|Format|
index ca34602344b5e41dd38251a1883db1f2dda7a79a..1f135d9bb7ca6ebc2d0e546dd3f738c00e56219c 100755 (executable)
@@ -98,7 +98,8 @@ if [ $? -ne 0 ] ; then fail ; fi
 
 
 activity="compare output"
-diff -b -B $TEMPDIR/pspp.list - << EOF
+perl -pi -e s/^\s*\$//g $TEMPDIR/pspp.list
+diff -b  $TEMPDIR/pspp.list - << EOF | perl -e 's/^\s*$//g'
 1.1 DATA LIST.  Reading free-form data from file $TEMPDIR/data-list.data.
 +--------+------+
 |Variable|Format|
index c5d3ecfc4eaec05153aaaf725d8587ee6c59de16..2c43d3a7f2c2a6463fb94f98fec174e4ad96fa51 100755 (executable)
@@ -78,7 +78,8 @@ grep -i Brake $TEMPDIR/rename.sav
 if [ $? -eq 0 ] ; then fail ; fi
 
 activity="compare output"
-diff -B -b $TEMPDIR/pspp.list - <<EOF
+perl -pi -e s/^\s*\$//g $TEMPDIR/pspp.list
+diff  -b $TEMPDIR/pspp.list - <<EOF | perl -e 's/^\s*$//g'
 1.1 DATA LIST.  Reading free-form data from the command file.
 +----------+------+
 | Variable |Format|
index f9ae79abab3e93923a86e42701fa9c2229605118..7a992a16af6fbd421e430665c707f57e4ea7f71e 100755 (executable)
@@ -78,7 +78,8 @@ $SUPERVISOR $here/../src/pspp -o raw-ascii $TEMPDIR/split.stat
 if [ $? -ne 0 ] ; then no_result ; fi
 
 activity="compare results"
-diff -B -b $TEMPDIR/pspp.list - <<EOF
+perl -pi -e s/^\s*\$//g $TEMPDIR/pspp.list
+diff  -b $TEMPDIR/pspp.list - <<EOF | perl -e 's/^\s*$//g'
 Variable Value Label
 X            1
 
index 6e23c97f8a930a0cb4380e9604d4496045d4e1da..0931a0af0d5fde29b3fd208f44044a5842c3dffe 100755 (executable)
@@ -89,7 +89,8 @@ grep  'X=X' $TEMPDIR/foo.sav
 if [ $? -eq 0 ] ; then fail ; fi
 
 activity="compare output"
-diff -b -B -w $TEMPDIR/pspp.list - << EOF
+perl -pi -e s/^\s*\$//g $TEMPDIR/pspp.list
+diff -b  -w $TEMPDIR/pspp.list - << EOF | perl -e 's/^\s*$//g'
        X VARIABLE VARIAB_A VARIAB_B
 -------- -------- -------- --------
     1.00     1.00     1.00     2.00 
index 48f561bc795ece3b881e9c85343e2a78d75c2a8f..0dd6c5fe74bee9c599665c6524830ec72c23f916 100755 (executable)
@@ -79,7 +79,8 @@ $SUPERVISOR $here/../src/pspp -o raw-ascii $TESTFILE
 if [ $? -ne 0 ] ; then no_result ; fi
 
 activity="compare output"
-diff -b -B -w $TEMPDIR/pspp.list - << EOF
+perl -pi -e s/^\s*\$//g $TEMPDIR/pspp.list
+diff -b  -w $TEMPDIR/pspp.list - << EOF | perl -e 's/^\s*$//g'
 variable001 variable002 variable003 variable004
 ----------- ----------- ----------- -----------
        1.00        1.00        1.00        2.00  
index e149ac7995509997a0e406f94bce33fce78d66f4..01582f21c7b3b4474c56aa82d2628d066f0929ce 100755 (executable)
@@ -87,7 +87,8 @@ if [ $? -ne 0 ] ; then no_result ; fi
 
 
 activity="compare output"
-diff -B -b $TEMPDIR/pspp.list - <<EOF
+perl -pi -e s/^\s*\$//g $TEMPDIR/pspp.list
+diff  -b $TEMPDIR/pspp.list - <<EOF | perl -e 's/^\s*$//g'
 1.1 DATA LIST.  Reading free-form data from the command file.
 +--------+------+
 |Variable|Format|
index 2e18365c8e3eaa67de064138fb747b83d02eef0b..488cf20a81a64b42af8b831d9889c52e4c79900f 100755 (executable)
@@ -70,7 +70,8 @@ $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
+perl -pi -e s/^\s*\$//g $TEMPDIR/pspp.list
+diff  -b $TEMPDIR/pspp.list - <<EOF | perl -e 's/^\s*$//g'
 1.1 DATA LIST.  Reading free-form data from the command file.
 +--------+------+
 |Variable|Format|
index ca0cca4577e92c32a45d5cdb5ee6535ca905cfeb..8e388afa6ae8db82a18e310f157874bc2c42f24b 100755 (executable)
@@ -77,7 +77,8 @@ $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
+perl -pi -e s/^\s*\$//g $TEMPDIR/pspp.list
+diff  -b $TEMPDIR/pspp.list - <<EOF | perl -e 's/^\s*$//g'
 1.1 DATA LIST.  Reading free-form data from the command file.
 +--------+------+
 |Variable|Format|
index b3ef8415b03efd06a5ce76c5dfad37e5949f159d..7932b707c8882719b9b59fef0530d668f98b27aa 100755 (executable)
@@ -69,7 +69,8 @@ $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
+perl -pi -e s/^\s*\$//g $TEMPDIR/pspp.list
+diff  -b $TEMPDIR/pspp.list - <<EOF | perl -e 's/^\s*$//g'
 1.1 DATA LIST.  Reading free-form data from the command file.
 +--------+------+
 |Variable|Format|
index 606c0a4c148c4922f2f6d07b956c1933f34a7e50..93f4c01dd601330ec709eba031f4d3d46c0b0662 100755 (executable)
@@ -74,7 +74,8 @@ $SUPERVISOR $here/../src/pspp -o raw-ascii $TEMPDIR/tabs.stat
 if [ $? -ne 0 ] ; then no_result ; fi
 
 
-diff -B -b $TEMPDIR/pspp.list - << EOF
+perl -pi -e s/^\s*\$//g $TEMPDIR/pspp.list
+diff  -b $TEMPDIR/pspp.list - << EOF | perl -e 's/^\s*$//g'
 1.1 DATA LIST.  Reading 1 record from the command file.
 +--------+------+-------+------+
 |Variable|Record|Columns|Format|
index a5d74e1251338f04293d1991dae0305050a95818..1fc45c70e3948583bdef95c8b9128f794ccefac0 100755 (executable)
@@ -75,7 +75,8 @@ if [ $? -ne 0 ] ; then no_result ; fi
 
 
 activity="compare results"
-diff -b -B $TEMPDIR/pspp.list - << EOF
+perl -pi -e s/^\s*\$//g $TEMPDIR/pspp.list
+diff -b  $TEMPDIR/pspp.list - << EOF | perl -e 's/^\s*$//g'
 1.1 DATA LIST.  Reading free-form data from the command file.
 +--------+------+
 |Variable|Format|
index bbbb7b44fefeb82617065afdbd2c9a09b1a4bff7..415314d62f3424009493bd0e065badad0dec78ba 100755 (executable)
@@ -76,7 +76,8 @@ if [ $? -ne 0 ] ; then no_result ; fi
 
 
 activity="check results"
-diff -B -b $TEMPDIR/pspp.list - << EOF
+perl -pi -e s/^\s*\$//g $TEMPDIR/pspp.list
+diff  -b $TEMPDIR/pspp.list - << EOF | perl -e 's/^\s*$//g'
  X
 --
  1
index d2840edd807b65f7035e7fc2c9d7b68badf692c8..44995fc1b68404587605ab9c3265d4add48c34b8 100755 (executable)
@@ -66,7 +66,8 @@ $SUPERVISOR $here/../src/pspp --testing-mode -o raw-ascii $TESTFILE
 if [ $? -ne 0 ] ; then no_result ; fi
 
 activity="compare results"
-diff -B -b $TEMPDIR/pspp.list - <<EOF
+perl -pi -e s/^\s*\$//g $TEMPDIR/pspp.list
+diff  -b $TEMPDIR/pspp.list - <<EOF | perl -e 's/^\s*$//g'
 1.1 DATA LIST.  Reading 1 record from file $top_srcdir/tests/weighting.data.
 +--------+------+-------+------+
 |Variable|Record|Columns|Format|