diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/test/test-execute.c | 2 | ||||
-rw-r--r-- | src/test/test-util.c | 4 |
2 files changed, 4 insertions, 2 deletions
diff --git a/src/test/test-execute.c b/src/test/test-execute.c index 85deb27f43..60466f0d3f 100644 --- a/src/test/test-execute.c +++ b/src/test/test-execute.c @@ -164,7 +164,7 @@ int main(int argc, char *argv[]) { r = manager_new(SYSTEMD_USER, true, &m); if (IN_SET(r, -EPERM, -EACCES, -EADDRINUSE, -EHOSTDOWN, -ENOENT)) { printf("Skipping test: manager_new: %s", strerror(-r)); - return -EXIT_TEST_SKIP; + return EXIT_TEST_SKIP; } assert_se(r >= 0); assert_se(manager_startup(m, NULL, NULL) >= 0); diff --git a/src/test/test-util.c b/src/test/test-util.c index 20e711d415..fe54586eee 100644 --- a/src/test/test-util.c +++ b/src/test/test-util.c @@ -35,6 +35,7 @@ #include "def.h" #include "fileio.h" #include "conf-parser.h" +#include "virt.h" static void test_streq_ptr(void) { assert_se(streq_ptr(NULL, NULL)); @@ -544,7 +545,8 @@ static void test_get_process_comm(void) { assert_se(r >= 0 || r == -EACCES); log_info("self strlen(environ): '%zd'", strlen(env)); - assert_se(get_ctty_devnr(1, &h) == -ENOENT); + if (!detect_container(NULL)) + assert_se(get_ctty_devnr(1, &h) == -ENOENT); getenv_for_pid(1, "PATH", &i); log_info("pid1 $PATH: '%s'", strna(i)); |