mirror of
https://github.com/systemd/systemd.git
synced 2024-12-25 01:34:28 +03:00
tests: skip process 1 tests if systemd not is running
No point running tests against process 1 if systemd is not running as that process. This is a rework of an unpublished patch by @9muir.
This commit is contained in:
parent
40a23924ef
commit
76c19e9f6c
@ -40,6 +40,7 @@
|
||||
#include "stdio-util.h"
|
||||
#include "string-util.h"
|
||||
#include "terminal-util.h"
|
||||
#include "test-helper.h"
|
||||
#include "util.h"
|
||||
#include "virt.h"
|
||||
|
||||
@ -357,7 +358,7 @@ int main(int argc, char *argv[]) {
|
||||
(void) parse_pid(argv[1], &pid);
|
||||
test_get_process_comm(pid);
|
||||
} else {
|
||||
test_get_process_comm(1);
|
||||
TEST_REQ_RUNNING_SYSTEMD(test_get_process_comm(1));
|
||||
test_get_process_comm(getpid());
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user