Lines Matching defs:unit
33 _cleanup_free_ char *unit = NULL;
36 r = cg_path_decode_unit(path, &unit);
37 printf("%s: %s → %s %d expected %s %d\n", __func__, path, unit, r, result, code);
39 assert_se(streq_ptr(unit, result));
55 _cleanup_free_ char *unit = NULL;
58 r = cg_path_get_unit(path, &unit);
59 printf("%s: %s → %s %d expected %s %d\n", __func__, path, unit, r, result, code);
61 assert_se(streq_ptr(unit, result));
79 _cleanup_free_ char *unit = NULL;
82 r = cg_path_get_user_unit(path, &unit);
83 printf("%s: %s → %s %d expected %s %d\n", __func__, path, unit, r, result, code);
85 assert_se(streq_ptr(unit, result));
188 _cleanup_free_ char *path = NULL, *path_shifted = NULL, *session = NULL, *unit = NULL, *user_unit = NULL, *machine = NULL, *slice = NULL;
207 cg_pid_get_unit(pid, &unit);
218 unit,
262 static void test_slice_to_path_one(const char *unit, const char *path, int error) {
265 assert_se(cg_slice_to_path(unit, &ret) == error);