From 54f6333410ffd570e62717d9e77c5c987175e397 Mon Sep 17 00:00:00 2001 From: Michael Biebl Date: Thu, 24 Dec 2015 00:24:58 +0100 Subject: Imported Upstream version 1.0.10 --- src/platform/tests/monitor.c | 22 +++++++++++++--------- 1 file changed, 13 insertions(+), 9 deletions(-) (limited to 'src/platform/tests/monitor.c') diff --git a/src/platform/tests/monitor.c b/src/platform/tests/monitor.c index 9aff1047..f1058db8 100644 --- a/src/platform/tests/monitor.c +++ b/src/platform/tests/monitor.c @@ -3,10 +3,13 @@ #include #include -#include "nm-fake-platform.h" #include "nm-linux-platform.h" #include "nm-logging.h" +#include "nm-test-utils.h" + +NMTST_DEFINE (); + int main (int argc, char **argv) { @@ -16,15 +19,16 @@ main (int argc, char **argv) g_type_init (); #endif + if (!g_getenv ("G_MESSAGES_DEBUG")) + g_setenv ("G_MESSAGES_DEBUG", "all", TRUE); + + nmtst_init_with_logging (&argc, &argv, "DEBUG", "ALL"); + + nm_log_info (LOGD_PLATFORM, "platform monitor start"); + loop = g_main_loop_new (NULL, FALSE); - nm_logging_setup ("debug", NULL, NULL, NULL); - openlog (G_LOG_DOMAIN, LOG_CONS | LOG_PERROR, LOG_DAEMON); - - g_assert (argc <= 2); - if (argc > 1 && !g_strcmp0 (argv[1], "--fake")) - nm_fake_platform_setup (); - else - nm_linux_platform_setup (); + + nm_linux_platform_setup (); g_main_loop_run (loop); -- cgit 1.3.0-6-gf8a5