diff --git a/src/test/test-acl-util.c b/src/test/test-acl-util.c index 7b66e189ba..70ffdbc519 100644 --- a/src/test/test-acl-util.c +++ b/src/test/test-acl-util.c @@ -49,7 +49,7 @@ static void test_add_acls_for_user(void) { assert_se(system(cmd) == 0); if (getuid() == 0) { - const char *nobody = "nobody"; + const char *nobody = NOBODY_USER_NAME; r = get_user_creds(&nobody, &uid, NULL, NULL, NULL); if (r < 0) uid = 0; diff --git a/src/test/test-capability.c b/src/test/test-capability.c index 6c41e1ca15..e5db52d404 100644 --- a/src/test/test-capability.c +++ b/src/test/test-capability.c @@ -108,7 +108,7 @@ static int setup_tests(bool *run_ambient) { struct passwd *nobody; int r; - nobody = getpwnam("nobody"); + nobody = getpwnam(NOBODY_USER_NAME); if (!nobody) { log_error_errno(errno, "Could not find nobody user: %m"); return -EXIT_TEST_SKIP;