projects
/
systemd
/
.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
91bd0b9
)
test: don't overwrite TESTDIR if already set
author
Frantisek Sumsal
<frantisek@sumsal.cz>
Tue, 12 Mar 2019 21:44:25 +0000
(22:44 +0100)
committer
Frantisek Sumsal
<frantisek@sumsal.cz>
Wed, 13 Mar 2019 19:55:34 +0000
(20:55 +0100)
(cherry picked from commit
3f50fff536d715aee5e5195ec60e2af047b73c7f
)
test/test-functions
patch
|
blob
|
history
diff --git
a/test/test-functions
b/test/test-functions
index 670c2625f749171455cf7830967c5995c4fa1ac1..af9d16140f3bb06214011cb139406e50b6865f6f 100644
(file)
--- a/
test/test-functions
+++ b/
test/test-functions
@@
-711,8
+711,13
@@
inst_libs() {
import_testdir() {
[[ -e $STATEFILE ]] && . $STATEFILE
- if [[ -z "$TESTDIR" ]] || [[ ! -d "$TESTDIR" ]]; then
- TESTDIR=$(mktemp --tmpdir=/var/tmp -d -t systemd-test.XXXXXX)
+ if [[ ! -d "$TESTDIR" ]]; then
+ if [[ -z "$TESTDIR" ]]; then
+ TESTDIR=$(mktemp --tmpdir=/var/tmp -d -t systemd-test.XXXXXX)
+ else
+ mkdir -p "$TESTDIR"
+ fi
+
echo "TESTDIR=\"$TESTDIR\"" > $STATEFILE
export TESTDIR
fi