]> git.ipfire.org Git - thirdparty/systemd.git/blobdiff - src/udev/test-udev-builtin.c
test: Use TEST macros in more places
[thirdparty/systemd.git] / src / udev / test-udev-builtin.c
index 21a8ea3fa6f004209932d7c696ca3922c6bb2662..2ce7f196fdc60194b13ebfea9899d2b7963cbc56 100644 (file)
@@ -3,9 +3,7 @@
 #include "tests.h"
 #include "udev-builtin.h"
 
-static void test_udev_builtin_cmd_to_ptr(void) {
-        log_info("/* %s */", __func__);
-
+TEST(udev_builtin_cmd_to_ptr) {
         /* Those could have been static asserts, but ({}) is not allowed there. */
 #if HAVE_BLKID
         assert_se(UDEV_BUILTIN_CMD_TO_PTR(UDEV_BUILTIN_BLKID));
@@ -19,8 +17,4 @@ static void test_udev_builtin_cmd_to_ptr(void) {
         assert_se(PTR_TO_UDEV_BUILTIN_CMD((void*) 10000) == _UDEV_BUILTIN_INVALID);
 }
 
-int main(int argc, char *argv[]) {
-        test_setup_logging(LOG_DEBUG);
-
-        test_udev_builtin_cmd_to_ptr();
-}
+DEFINE_TEST_MAIN(LOG_DEBUG);