summaryrefslogtreecommitdiff
path: root/src/busctl
diff options
context:
space:
mode:
authorJan Janssen <medhefgo@web.de>2022-03-14 10:37:27 +0100
committerJan Janssen <medhefgo@web.de>2022-03-16 14:50:12 +0100
commit68da8adf54d7ab88610c161a1c7dd2819eb96886 (patch)
tree0a1f175eb14cb1e984c63f309641cf17df416e66 /src/busctl
parent45cab6e3c1d542d66c293a3a722c08412386f335 (diff)
downloadsystemd-68da8adf54d7ab88610c161a1c7dd2819eb96886.tar.gz
test: Use TEST macros in more places
Diffstat (limited to 'src/busctl')
-rw-r--r--src/busctl/test-busctl-introspect.c12
1 files changed, 2 insertions, 10 deletions
diff --git a/src/busctl/test-busctl-introspect.c b/src/busctl/test-busctl-introspect.c
index 216a9a3c3b..d0800d2360 100644
--- a/src/busctl/test-busctl-introspect.c
+++ b/src/busctl/test-busctl-introspect.c
@@ -313,7 +313,7 @@ static int on_path(const char *path, void *userdata) {
return 0;
}
-static void test_introspect_on_path(void) {
+TEST(introspect_on_path) {
static const XMLIntrospectOps ops = {
.on_path = on_path,
};
@@ -321,8 +321,6 @@ static void test_introspect_on_path(void) {
_cleanup_set_free_ Set *paths = NULL;
_cleanup_free_ char **l = NULL;
- log_info("/* %s */", __func__);
-
assert_se(set_put_strdup(&paths, "/") > 0);
log_debug("/* parse_xml_introspect(\"/\") */");
@@ -363,10 +361,4 @@ static void test_introspect_on_path(void) {
assert_se(strv_equal(l, expected));
}
-int main(int argc, char *argv[]) {
- test_setup_logging(LOG_DEBUG);
-
- test_introspect_on_path();
-
- return 0;
-}
+DEFINE_TEST_MAIN(LOG_DEBUG);