diff options
author | Danila Kiver <danila.kiver@mail.ru> | 2019-07-06 17:41:29 +0300 |
---|---|---|
committer | Danila Kiver <danila.kiver@mail.ru> | 2019-07-06 17:41:29 +0300 |
commit | 1f435bf92cc5e828cb36e658d695070473a41f96 (patch) | |
tree | 269f725eb448293000ad92b86f0a7263ceab9de8 | |
parent | c490754ff769f3327fb165fad87baf515210fbac (diff) | |
download | podman-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>
-rw-r--r-- | test/system/250-generate-systemd.bats | 6 |
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() { |