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.
@@ -12,7 +12,11 @@ UNIT_FILE="$UNIT_DIR/$SERVICE_NAME.service"
function setup() {
basic_setup
+
+ if [ ! -d "$UNIT_DIR" ]; then
mkdir -p "$UNIT_DIR"
+ systemctl --user daemon-reload
+ fi
}
function teardown() {
