Improve gtype test coverage

This commit is contained in:
Matthias Clasen 2013-05-29 08:34:24 -04:00
parent 07168724d7
commit db1c83a516
4 changed files with 11 additions and 0 deletions

View File

@ -150,6 +150,9 @@ main (int argc, char **argv)
g_thread_join (thread);
}
g_object_unref (test1);
g_object_unref (test2);
g_print ("stopped\n");
return 0;

View File

@ -183,6 +183,8 @@ run_thread (GTest * test)
}
}
g_object_unref (test);
return NULL;
}

View File

@ -193,5 +193,7 @@ main (int argc, char **argv)
g_assert (count == test->dummy);
g_object_unref (test);
return 0;
}

View File

@ -151,6 +151,7 @@ int
main (int argc, char **argv)
{
MyBadger * badger1, * badger2;
gpointer test;
g_print ("START: %s\n", argv[0]);
g_log_set_always_fatal (G_LOG_LEVEL_WARNING | G_LOG_LEVEL_CRITICAL | g_log_set_always_fatal (G_LOG_FATAL_MASK));
@ -161,6 +162,9 @@ main (int argc, char **argv)
g_object_set (badger1, "mama", badger2, NULL);
g_assert_cmpuint (badger1->mama_notify_count, ==, 1);
g_assert_cmpuint (badger2->mama_notify_count, ==, 1);
g_object_get (badger1, "mama", &test, NULL);
g_assert (test == badger2);
g_object_unref (test);
g_object_unref (badger1);
g_object_unref (badger2);