diff options
author | Junio C Hamano <gitster@pobox.com> | 2021-07-08 13:15:02 -0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2021-07-08 13:15:02 -0700 |
commit | 62473695d2e3ef9c07b71d8decce92bc6cd5c469 (patch) | |
tree | 2dcc6dd680106440d085e092c93961b1fc041229 /t/test-lib-functions.sh | |
parent | Merge branch 'jx/sideband-cleanup' (diff) | |
parent | t: use portable wrapper for readlink(1) (diff) | |
download | tgif-62473695d2e3ef9c07b71d8decce92bc6cd5c469.tar.xz |
Merge branch 'jk/test-without-readlink-1'
Some test scripts assumed that readlink(1) was universally
installed and available, which is not the case.
* jk/test-without-readlink-1:
t: use portable wrapper for readlink(1)
Diffstat (limited to 't/test-lib-functions.sh')
-rw-r--r-- | t/test-lib-functions.sh | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/t/test-lib-functions.sh b/t/test-lib-functions.sh index f0448daa74..b2810478a2 100644 --- a/t/test-lib-functions.sh +++ b/t/test-lib-functions.sh @@ -1708,3 +1708,9 @@ test_region () { return 0 } + +# Print the destination of symlink(s) provided as arguments. Basically +# the same as the readlink command, but it's not available everywhere. +test_readlink () { + perl -le 'print readlink($_) for @ARGV' "$@" +} |