mirror of
https://github.com/GothenburgBitFactory/taskwarrior.git
synced 2025-06-26 10:54:26 +02:00
Tests: expose 'args' passed to hook scripts
- Useful to validate that all the expected arguments were passed with correct escaping. - Update test/template.t with one use-case for 'args'
This commit is contained in:
parent
09d86eb165
commit
fd17a68930
4 changed files with 12 additions and 8 deletions
|
@ -6,7 +6,7 @@ IN="${ORIGINALHOOK}.log.in"
|
|||
OUT="${ORIGINALHOOK}.log.out"
|
||||
|
||||
# Let it know that we were executed
|
||||
echo "% Called at $(python -c 'import time; print(time.time())')" >> ${IN}
|
||||
echo "% Called at $(python -c 'import time; print(time.time())') with '$@'" >> ${IN}
|
||||
|
||||
# Log what arrives via stdin to ${IN} and what comes via stdout to ${OUT}
|
||||
$ORIGINALHOOK "$@" < <(tee -a ${IN}) > >(tee -a ${OUT})
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue