summaryrefslogtreecommitdiff
path: root/t
diff options
context:
space:
mode:
authorLibravatar Johannes Schindelin <johannes.schindelin@gmx.de>2016-01-12 08:57:57 +0100
committerLibravatar Junio C Hamano <gitster@pobox.com>2016-01-12 10:41:34 -0800
commit7d1aaa684d42964b8b287b8c9450184dfd5bce85 (patch)
treef5b5a6d524c2474fd2be9dc8d48f2edcfb6b560c /t
parentcompat/basename.c: provide a dirname() compatibility function (diff)
downloadtgif-7d1aaa684d42964b8b287b8c9450184dfd5bce85.tar.xz
t0060: verify that basename() and dirname() work as expected
Unfortunately, some libgen implementations yield outcomes different from what Git expects. For example, mingw-w64-crt provides a basename() function, that shortens `path0/` to `path`! So let's verify that the basename() and dirname() functions we use conform to what Git expects. Derived-from-code-by: Ramsay Jones <ramsay@ramsayjones.plus.com> Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't')
-rwxr-xr-xt/t0060-path-utils.sh3
1 files changed, 3 insertions, 0 deletions
diff --git a/t/t0060-path-utils.sh b/t/t0060-path-utils.sh
index 93605f42f2..584a0decfc 100755
--- a/t/t0060-path-utils.sh
+++ b/t/t0060-path-utils.sh
@@ -59,6 +59,9 @@ case $(uname -s) in
;;
esac
+test_expect_success basename 'test-path-utils basename'
+test_expect_success dirname 'test-path-utils dirname'
+
norm_path "" ""
norm_path . ""
norm_path ./ ""