summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorDanila Kiver <danila.kiver@mail.ru>2019-07-06 17:41:29 +0300
committerDanila Kiver <danila.kiver@mail.ru>2019-07-06 17:41:29 +0300
commit1f435bf92cc5e828cb36e658d695070473a41f96 (patch)
tree269f725eb448293000ad92b86f0a7263ceab9de8 /test
parentc490754ff769f3327fb165fad87baf515210fbac (diff)
downloadpodman-1f435bf92cc5e828cb36e658d695070473a41f96.tar.gz
podman-1f435bf92cc5e828cb36e658d695070473a41f96.tar.bz2
podman-1f435bf92cc5e828cb36e658d695070473a41f96.zip
Reload systemd daemon on creation of units location dir in tests.
Systemd manager drops non-existent directories from the units search path during initialization, thus, creation of UNIT_DIR, if it did not exist before, requres reloading the daemon. Signed-off-by: Danila Kiver <danila.kiver@mail.ru>
Diffstat (limited to 'test')
-rw-r--r--test/system/250-generate-systemd.bats6
1 files changed, 5 insertions, 1 deletions
diff --git a/test/system/250-generate-systemd.bats b/test/system/250-generate-systemd.bats
index 20a73c726..a8eb3b0a6 100644
--- a/test/system/250-generate-systemd.bats
+++ b/test/system/250-generate-systemd.bats
@@ -12,7 +12,11 @@ UNIT_FILE="$UNIT_DIR/$SERVICE_NAME.service"
function setup() {
basic_setup
- mkdir -p "$UNIT_DIR"
+
+ if [ ! -d "$UNIT_DIR" ]; then
+ mkdir -p "$UNIT_DIR"
+ systemctl --user daemon-reload
+ fi
}
function teardown() {