chiark / gitweb /
Fix service file to match installed elogind binary location
[elogind.git] / src / test / test-helper.h
index f75dd3374ad3e674e4e4e5a468baa6f2bead9741..ddb10f88fd1956010a6cc411b89f9073d6d3bf77 100644 (file)
@@ -1,5 +1,3 @@
-/*-*- Mode: C; c-basic-offset: 8; indent-tabs-mode: nil -*-*/
-
 #pragma once
 
 /***
 
 #include "sd-daemon.h"
 
+#include "macro.h"
+
 #define TEST_REQ_RUNNING_SYSTEMD(x)                                 \
         if (sd_booted() > 0) {                                      \
                 x;                                                  \
         } else {                                                    \
                 printf("systemd not booted skipping '%s'\n", #x);   \
         }
+
+#define MANAGER_SKIP_TEST(r)                                    \
+        IN_SET(r,                                               \
+               -EPERM,                                          \
+               -EACCES,                                         \
+               -EADDRINUSE,                                     \
+               -EHOSTDOWN,                                      \
+               -ENOENT,                                         \
+               -ENOMEDIUM /* cannot determine cgroup */         \
+               )