tests: add missing XDG_RUNTIME_DIR env variable
Otherwise the test fails because specifier_runtime() returns -ENOTSUP when XDG_RUNTIME_DIR is not set.
This commit is contained in:
parent
94655a1670
commit
6dbfd10471
|
@ -146,6 +146,7 @@ static int test_unit_printf(void) {
|
|||
|
||||
assert_se(setenv("USER", "root", 1) == 0);
|
||||
assert_se(setenv("HOME", "/root", 1) == 0);
|
||||
assert_se(setenv("XDG_RUNTIME_DIR", "/run/user/1/", 1) == 0);
|
||||
|
||||
assert_se(u = unit_new(m, sizeof(Service)));
|
||||
assert_se(unit_add_name(u, "blah.service") == 0);
|
||||
|
|
Loading…
Reference in a new issue