Hello,

the error output in some tests is not as useful as it could be. This patch 
amend that.

Description:

Do not compare actual and expected output with the "quiet" switch, to get some 
info more useful than "The files xxx and yyy differ" in case of failure

Use the correct error output file in unzip_tests

Regards
    Jiri Palecek

Signed-Off-By: Jiri Palecek <[email protected]>
---
 testcases/commands/fileutils/ln/ln_tests.sh |    2 +-
 testcases/commands/gzip/gzip_tests.sh       |    4 ++--
 testcases/commands/unzip/unzip_tests.sh     |    2 +-
 3 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/testcases/commands/fileutils/ln/ln_tests.sh 
b/testcases/commands/fileutils/ln/ln_tests.sh
index e1704f1..ea9bf44 100755
--- a/testcases/commands/fileutils/ln/ln_tests.sh
+++ b/testcases/commands/fileutils/ln/ln_tests.sh
@@ -217,7 +217,7 @@ test01()

        $LTPBIN/tst_resm TINFO \
            "Test #1: comparing expected out and actual output file"
-       diff -w -B -q $LTPTMP/tst_ln.out $LTPTMP/tst_ln.exp > 
$LTPTMP/tst_ln.err 2>&1 \
+       diff -w -B $LTPTMP/tst_ln.out $LTPTMP/tst_ln.exp > $LTPTMP/tst_ln.err 
2>&1 \
                || RC=$?
        if [ $RC -ne 0 ]
        then
diff --git a/testcases/commands/gzip/gzip_tests.sh 
b/testcases/commands/gzip/gzip_tests.sh
index ddd26df..facd8de 100755
--- a/testcases/commands/gzip/gzip_tests.sh
+++ b/testcases/commands/gzip/gzip_tests.sh
@@ -214,7 +214,7 @@ test01()
        creat_expout $numdirs $numfiles $LTPTMP/tst_gzip.tmp .gz

        tst_resm TINFO "Test #1: comparing expected out and actual output file"
-       diff -w -B -q $LTPTMP/tst_gzip.out $LTPTMP/tst_gzip.exp \
+       diff -w -B $LTPTMP/tst_gzip.out $LTPTMP/tst_gzip.exp \
                > $LTPTMP/tst_gzip.err 2>&1 || RC=$?
        if [ $RC -ne 0 ]
        then
@@ -284,7 +284,7 @@ test02()
        creat_expout $numdirs $numfiles $LTPTMP/tst_gzip.tmp

        tst_resm TINFO "Test #2: comparing expected out and actual output file"
-       diff -w -B -q $LTPTMP/tst_gzip.out $LTPTMP/tst_gzip.exp \
+       diff -w -B $LTPTMP/tst_gzip.out $LTPTMP/tst_gzip.exp \
                > $LTPTMP/tst_gzip.err 2>&1 || RC=$?
        if [ $RC -ne 0 ]
        then
diff --git a/testcases/commands/unzip/unzip_tests.sh 
b/testcases/commands/unzip/unzip_tests.sh
index 10cac8d..a55ff8c 100755
--- a/testcases/commands/unzip/unzip_tests.sh
+++ b/testcases/commands/unzip/unzip_tests.sh
@@ -172,7 +172,7 @@ test01()
                diff -iwB $LTPTMP/tst_unzip.out $LTPTMP/tst_unzip.out.exp > 
$LTPTMP/tst_unzip.out.err || RC=$?
                if [ $RC -ne 0 ]
                then
-                       tst_res TFAIL $LTPTMP/tst_unzip.err \
+                       tst_res TFAIL $LTPTMP/tst_unzip.out.err \
                                "Test #1: unzip output differs from expected 
output. Details"
                else
                        tst_resm TINFO "Test #1: check if 
$PWD/tmp/tst_unzip.dir exits."

-- 
1.6.0.6



------------------------------------------------------------------------------
_______________________________________________
Ltp-list mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ltp-list

Reply via email to