From: Mark Wielaard Date: Sat, 30 May 2015 21:00:40 +0000 (+0200) Subject: tests: Always print reason when skipping test. X-Git-Tag: elfutils-0.162~27 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=7ec8d27033bea05ce1be4601e6784134c4a66c9f;p=thirdparty%2Felfutils.git tests: Always print reason when skipping test. Make sure the reason a test is SKIPPED is added to the test-suite.log. Signed-off-by: Mark Wielaard --- diff --git a/tests/ChangeLog b/tests/ChangeLog index 94ee1f7d3..19878ac46 100644 --- a/tests/ChangeLog +++ b/tests/ChangeLog @@ -1,3 +1,16 @@ +2015-05-30 Mark Wielaard + + * backtrace-subr.sh (check_native_core): Notice core file couldn't be + generated before skipping. + * run-addr2line-i-demangle-test.sh: Notice demangler is unsupported + before skipping. + * run-backtrace-demangle.sh: Likewise. + * run-stack-demangled-test.sh: Likewise. + * run-backtrace-native-biarch.sh: Notice biarch testing is disabled + before skipping. + * run-backtrace-native-core-biarch.sh: Likewise. + * test-subr.sh (testfiles): Notice how bunzip2 fails before skipping. + 2015-05-20 Mark Wielaard * run-addr2line-i-test.sh: Add pretty test. diff --git a/tests/backtrace-subr.sh b/tests/backtrace-subr.sh index f04721cff..790b4f445 100644 --- a/tests/backtrace-subr.sh +++ b/tests/backtrace-subr.sh @@ -1,4 +1,4 @@ -# Copyright (C) 2013 Red Hat, Inc. +# Copyright (C) 2013, 2015 Red Hat, Inc. # This file is part of elfutils. # # This file is free software; you can redistribute it and/or modify @@ -135,7 +135,7 @@ check_native_core() if [ -f core ]; then mv core "$core" fi - if [ ! -f "$core" ]; then exit 77; fi + if [ ! -f "$core" ]; then echo "No $core file generated"; exit 77; fi if [ "x$SAVED_VALGRIND_CMD" != "x" ]; then VALGRIND_CMD="$SAVED_VALGRIND_CMD" diff --git a/tests/run-addr2line-i-demangle-test.sh b/tests/run-addr2line-i-demangle-test.sh index e709acfaf..1af85622e 100755 --- a/tests/run-addr2line-i-demangle-test.sh +++ b/tests/run-addr2line-i-demangle-test.sh @@ -16,6 +16,7 @@ # along with this program. If not, see . if test -n "$ELFUTILS_DISABLE_DEMANGLE"; then + echo "demangler unsupported" exit 77 fi diff --git a/tests/run-backtrace-demangle.sh b/tests/run-backtrace-demangle.sh index 6e18e77f9..71a735181 100755 --- a/tests/run-backtrace-demangle.sh +++ b/tests/run-backtrace-demangle.sh @@ -1,5 +1,5 @@ #! /bin/bash -# Copyright (C) 2014 Red Hat, Inc. +# Copyright (C) 2014, 2015 Red Hat, Inc. # This file is part of elfutils. # # This file is free software; you can redistribute it and/or modify @@ -16,6 +16,7 @@ # along with this program. If not, see . if test -n "$ELFUTILS_DISABLE_DEMANGLE"; then + echo "demangler unsupported" exit 77 fi diff --git a/tests/run-backtrace-native-biarch.sh b/tests/run-backtrace-native-biarch.sh index 3a407c896..2afe38a5e 100755 --- a/tests/run-backtrace-native-biarch.sh +++ b/tests/run-backtrace-native-biarch.sh @@ -1,5 +1,5 @@ #! /bin/bash -# Copyright (C) 2013 Red Hat, Inc. +# Copyright (C) 2013, 2015 Red Hat, Inc. # This file is part of elfutils. # # This file is free software; you can redistribute it and/or modify @@ -16,6 +16,7 @@ # along with this program. If not, see . if test -n "$ELFUTILS_DISABLE_BIARCH"; then + echo "biarch testing disabled" exit 77 fi diff --git a/tests/run-backtrace-native-core-biarch.sh b/tests/run-backtrace-native-core-biarch.sh index fbd80256e..02552ce9a 100755 --- a/tests/run-backtrace-native-core-biarch.sh +++ b/tests/run-backtrace-native-core-biarch.sh @@ -1,5 +1,5 @@ #! /bin/bash -# Copyright (C) 2013 Red Hat, Inc. +# Copyright (C) 2013, 2015 Red Hat, Inc. # This file is part of elfutils. # # This file is free software; you can redistribute it and/or modify @@ -16,6 +16,7 @@ # along with this program. If not, see . if test -n "$ELFUTILS_DISABLE_BIARCH"; then + echo "biarch testing disabled" exit 77 fi diff --git a/tests/run-stack-demangled-test.sh b/tests/run-stack-demangled-test.sh index 0d9f8f3ed..98f8ff8ef 100755 --- a/tests/run-stack-demangled-test.sh +++ b/tests/run-stack-demangled-test.sh @@ -16,6 +16,7 @@ # along with this program. If not, see . if test -n "$ELFUTILS_DISABLE_DEMANGLE"; then + echo "demangler unsupported" exit 77 fi diff --git a/tests/test-subr.sh b/tests/test-subr.sh index 5e796b4df..f397aed1a 100644 --- a/tests/test-subr.sh +++ b/tests/test-subr.sh @@ -1,5 +1,5 @@ #! /bin/sh -# Copyright (C) 2005-2014 Red Hat, Inc. +# Copyright (C) 2005-2015 Red Hat, Inc. # This file is part of elfutils. # # This file is free software; you can redistribute it and/or modify @@ -47,7 +47,7 @@ tempfiles() testfiles() { for file; do - bunzip2 -c ${abs_srcdir}/${file}.bz2 > ${file} 2>/dev/null || exit 77 + bunzip2 -c ${abs_srcdir}/${file}.bz2 > ${file} || exit 77 remove_files="$remove_files $file" done }