Gitweb: http://git.fedorahosted.org/git/?p=lvm2.git;a=commitdiff;h=c6bcfcba8541d053f... Commit: c6bcfcba8541d053f142496c30f437a694daf5ee Parent: c969e05aabb00b400d24e44c09c720f1cdebb351 Author: Zdenek Kabelac zkabelac@redhat.com AuthorDate: Tue Apr 14 09:48:57 2015 +0200 Committer: Zdenek Kabelac zkabelac@redhat.com CommitterDate: Tue Apr 14 10:11:36 2015 +0200
tests: stacktrace understands fullpath
$0 as name of script could be either relative or full path. When it's fullpath don't prepend $TESTOLDPWD. --- test/lib/utils.sh | 4 +++- 1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/test/lib/utils.sh b/test/lib/utils.sh index 488e338..1713cc9 100644 --- a/test/lib/utils.sh +++ b/test/lib/utils.sh @@ -166,7 +166,9 @@ STACKTRACE() { udevadm info --path "$i" || true done | sed -e "s,^,## UDEV: ," echo "<======== Script file "$(< TESTNAME)" ========>" - awk '{print "## Line:", NR, "\t", $0}' "$TESTOLDPWD/$0" + local script=$0 + test -f "$script" || script="$TESTOLDPWD/$0" + awk '{print "## Line:", NR, "\t", $0}' "$script" }
test -f SKIP_THIS_TEST && exit 200
lvm2-commits@lists.fedorahosted.org