aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorTed Gould <ted@canonical.com>2009-10-08 19:49:23 -0400
committerTed Gould <ted@canonical.com>2009-10-08 19:49:23 -0400
commit56450cfd530c876adc4ad33b1a5ab53a6a6078fa (patch)
tree5fe91fa8cf0bef5bd62471ee29931ebe552c9f4b /tests
parent66b0d1beb9907963f35dd36ccf3e193eb641f694 (diff)
downloadlibayatana-indicator-56450cfd530c876adc4ad33b1a5ab53a6a6078fa.tar.gz
libayatana-indicator-56450cfd530c876adc4ad33b1a5ab53a6a6078fa.tar.bz2
libayatana-indicator-56450cfd530c876adc4ad33b1a5ab53a6a6078fa.zip
Making it so that the null test checks for failure as we shoudln't have a null image and label. Also making it so that warnings don't cause the test to fail.
Diffstat (limited to 'tests')
-rw-r--r--tests/test-loader.c14
1 files changed, 12 insertions, 2 deletions
diff --git a/tests/test-loader.c b/tests/test-loader.c
index 16c0292..3dcc595 100644
--- a/tests/test-loader.c
+++ b/tests/test-loader.c
@@ -4,9 +4,9 @@
void destroy_cb (gpointer data, GObject * object);
void
-test_loader_filename_dummy_null (void)
+test_loader_filename_dummy_simple (void)
{
- IndicatorObject * object = indicator_object_new_from_file(BUILD_DIR "/.libs/libdummy-indicator-null.so");
+ IndicatorObject * object = indicator_object_new_from_file(BUILD_DIR "/.libs/libdummy-indicator-simple.so");
g_assert(object != NULL);
gboolean unreffed = FALSE;
@@ -19,6 +19,14 @@ test_loader_filename_dummy_null (void)
}
void
+test_loader_filename_dummy_null (void)
+{
+ IndicatorObject * object = indicator_object_new_from_file(BUILD_DIR "/.libs/libdummy-indicator-null.so");
+ g_assert(object == NULL);
+ return;
+}
+
+void
test_loader_filename_bad (void)
{
IndicatorObject * object = indicator_object_new_from_file("/this/file/should/not/exist.so");
@@ -68,5 +76,7 @@ main (int argc, char ** argv)
test_loader_creation_deletion_suite();
+ g_log_set_always_fatal(G_LOG_LEVEL_CRITICAL);
+
return g_test_run();
}