chiark
/
gitweb
/
~ianmdlvl
/
dgit.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
test suite: t-tstunt: When looking for real thing, strip stunt from PATH
[dgit.git]
/
tests
/
lib
diff --git
a/tests/lib
b/tests/lib
index 1def3d36394892aabc9ca6774444aa5fedc90950..1af0288aeace7db78adc3b6518af4529dc1972af 100644
(file)
--- a/
tests/lib
+++ b/
tests/lib
@@
-801,7
+801,14
@@
t-tstunt--save-real () {
local rc
local real
set +e
- real=$(type -p "$f")
+ real=$(
+ p=":$PATH:"
+ p="${p/:"$tmp/tstunt":/:}"
+ p="${p%:}"
+ p="${p#:}"
+ PATH="$p"
+ type -p "$f"
+ )
rc=$?
set -e