separate dirname and basename in non-tap format

This commit is contained in:
Thomas Levine 2016-02-28 13:23:34 +00:00
parent e8d3f84b92
commit 9c633a2029

8
urchin
View File

@ -242,16 +242,18 @@ report_outcome() {
if test "$prevdir" != "$currentdir"; then if test "$prevdir" != "$currentdir"; then
echo echo
fi fi
pretty_path="$(dirname -- "$path")/
$(basename -- "$path")"
case "$result" in case "$result" in
ok) ok)
# On success, print a green '✓' # On success, print a green '✓'
printf '\033[32m✓ \033[0m' printf '\033[32m✓ \033[0m'
printf '%s\n' "${path}" printf '%s\n' "${pretty_path}"
;; ;;
not_ok) not_ok)
# On not_ok, print a red '✗' # On not_ok, print a red '✗'
printf '\033[31m✗ \033[0m' printf '\033[31m✗ \033[0m'
printf '%s\n' "${path}" printf '%s\n' "${pretty_path}"
# Print output captured from not_ok test in red. # Print output captured from not_ok test in red.
printf '\033[31m' printf '\033[31m'
@ -260,7 +262,7 @@ report_outcome() {
printf '\033[0m' printf '\033[0m'
;; ;;
skip) skip)
printf ' %s\n' "${path}" printf '%s\n' "${pretty_path}"
;; ;;
esac esac
fi fi