mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-08-01 23:13:40 +02:00
Return a boolean instead of void.
2006-06-12 Emmanuele Bassi <ebassi@cvs.gnome.org> * glib/gbookmarkfile.h: * glib/gbookmarkfile.c (g_bookmark_file_remove_item): Return a boolean instead of void. * tests/bookmarkfile-test.c (test_modify): Add a test case for g_bookmark_file_remove_item().
This commit is contained in:
committed by
Emmanuele Bassi
parent
e39b793341
commit
cc37f43d1d
@@ -193,6 +193,13 @@ test_modify (GBookmarkFile *bookmark)
|
||||
g_assert (g_bookmark_file_has_group (bookmark, TEST_URI_1, "Test", NULL) == TRUE);
|
||||
g_assert (g_bookmark_file_has_group (bookmark, TEST_URI_1, "Fail", NULL) == FALSE);
|
||||
g_print ("ok\n");
|
||||
|
||||
g_print ("\t=> check remove...");
|
||||
g_assert (g_bookmark_file_remove_item (bookmark, TEST_URI_1, &error) == TRUE);
|
||||
test_assert_empty_error (&error);
|
||||
g_assert (g_bookmark_file_remove_item (bookmark, TEST_URI_1, &error) == FALSE);
|
||||
test_assert_not_empty_error (&error, G_BOOKMARK_FILE_ERROR, G_BOOKMARK_FILE_ERROR_URI_NOT_FOUND);
|
||||
g_print ("ok\n");
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
Reference in New Issue
Block a user