tests: Support saving temporary directory
This commit is contained in:
parent
42a3a68d17
commit
5e0d58dd72
|
|
@ -25,7 +25,11 @@ cd "$test_tmpdir"
|
||||||
touch "$test_tmpdir/.test$$"
|
touch "$test_tmpdir/.test$$"
|
||||||
|
|
||||||
die () {
|
die () {
|
||||||
|
if test -z "$HT_TESTS_SAVE_TEMPS"; then
|
||||||
test -f "$test_tmpdir/.test$$" && rm -rf "$test_tmpdir"
|
test -f "$test_tmpdir/.test$$" && rm -rf "$test_tmpdir"
|
||||||
|
else
|
||||||
|
echo "Temporary files saved in $test_tmpdir"
|
||||||
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
trap 'die' EXIT
|
trap 'die' EXIT
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue