summaryrefslogtreecommitdiff
path: root/src/test/test-unit-file.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/test-unit-file.c')
-rw-r--r--src/test/test-unit-file.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/test/test-unit-file.c b/src/test/test-unit-file.c
index 63a8a7d076..48133428df 100644
--- a/src/test/test-unit-file.c
+++ b/src/test/test-unit-file.c
@@ -48,6 +48,12 @@ static int test_unit_file_get_set(void) {
assert(h);
r = unit_file_get_list(UNIT_FILE_SYSTEM, NULL, h);
+
+ if (r == -EPERM || r == -EACCES) {
+ printf("Skipping test: unit_file_get_list: %s", strerror(-r));
+ return EXIT_TEST_SKIP;
+ }
+
log_full(r == 0 ? LOG_INFO : LOG_ERR,
"unit_file_get_list: %s", strerror(-r));
if (r < 0)