summaryrefslogtreecommitdiffstats
path: root/src/test/test-unit-file.c
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-06-12 03:50:42 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-06-12 03:50:42 +0000
commit78e9bb837c258ac0ec7712b3d612cc2f407e731e (patch)
treef515d16b6efd858a9aeb5b0ef5d6f90bf288283d /src/test/test-unit-file.c
parentAdding debian version 255.5-1. (diff)
downloadsystemd-78e9bb837c258ac0ec7712b3d612cc2f407e731e.tar.xz
systemd-78e9bb837c258ac0ec7712b3d612cc2f407e731e.zip
Merging upstream version 256.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'src/test/test-unit-file.c')
-rw-r--r--src/test/test-unit-file.c22
1 files changed, 11 insertions, 11 deletions
diff --git a/src/test/test-unit-file.c b/src/test/test-unit-file.c
index 9f8787b..63e5000 100644
--- a/src/test/test-unit-file.c
+++ b/src/test/test-unit-file.c
@@ -26,7 +26,7 @@ TEST(unit_validate_alias_symlink_and_warn) {
}
TEST(unit_file_build_name_map) {
- _cleanup_(lookup_paths_free) LookupPaths lp = {};
+ _cleanup_(lookup_paths_done) LookupPaths lp = {};
_cleanup_hashmap_free_ Hashmap *unit_ids = NULL;
_cleanup_hashmap_free_ Hashmap *unit_names = NULL;
const char *k, *dst;
@@ -88,18 +88,18 @@ TEST(unit_file_build_name_map) {
TEST(runlevel_to_target) {
in_initrd_force(false);
- assert_se(streq_ptr(runlevel_to_target(NULL), NULL));
- assert_se(streq_ptr(runlevel_to_target("unknown-runlevel"), NULL));
- assert_se(streq_ptr(runlevel_to_target("rd.unknown-runlevel"), NULL));
- assert_se(streq_ptr(runlevel_to_target("3"), SPECIAL_MULTI_USER_TARGET));
- assert_se(streq_ptr(runlevel_to_target("rd.rescue"), NULL));
+ ASSERT_STREQ(runlevel_to_target(NULL), NULL);
+ ASSERT_STREQ(runlevel_to_target("unknown-runlevel"), NULL);
+ ASSERT_STREQ(runlevel_to_target("rd.unknown-runlevel"), NULL);
+ ASSERT_STREQ(runlevel_to_target("3"), SPECIAL_MULTI_USER_TARGET);
+ ASSERT_STREQ(runlevel_to_target("rd.rescue"), NULL);
in_initrd_force(true);
- assert_se(streq_ptr(runlevel_to_target(NULL), NULL));
- assert_se(streq_ptr(runlevel_to_target("unknown-runlevel"), NULL));
- assert_se(streq_ptr(runlevel_to_target("rd.unknown-runlevel"), NULL));
- assert_se(streq_ptr(runlevel_to_target("3"), NULL));
- assert_se(streq_ptr(runlevel_to_target("rd.rescue"), SPECIAL_RESCUE_TARGET));
+ ASSERT_STREQ(runlevel_to_target(NULL), NULL);
+ ASSERT_STREQ(runlevel_to_target("unknown-runlevel"), NULL);
+ ASSERT_STREQ(runlevel_to_target("rd.unknown-runlevel"), NULL);
+ ASSERT_STREQ(runlevel_to_target("3"), NULL);
+ ASSERT_STREQ(runlevel_to_target("rd.rescue"), SPECIAL_RESCUE_TARGET);
}
static int intro(void) {