summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthias Clasen <mclasen@redhat.com>2012-06-04 05:59:27 -0400
committerMatthias Clasen <mclasen@redhat.com>2012-06-04 06:04:29 -0400
commit4ad5210b353b685dce0aae9bd7331838f6cc5f92 (patch)
tree686dade3f2ebdfae0ed0d6139b7e2a449c9fdf55
parent3129bac14c6ac5e991127f8cc51810c28306bbad (diff)
downloadglib-4ad5210b353b685dce0aae9bd7331838f6cc5f92.tar.gz
Improve GIcon test coverage
-rw-r--r--gio/tests/g-icon.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/gio/tests/g-icon.c b/gio/tests/g-icon.c
index 5c9778d78..0058278ab 100644
--- a/gio/tests/g-icon.c
+++ b/gio/tests/g-icon.c
@@ -43,6 +43,7 @@ test_g_icon_serialize (void)
GError *error;
gint origin;
GIcon *i;
+ GFile *file;
error = NULL;
@@ -51,6 +52,11 @@ test_g_icon_serialize (void)
uri = "file:///some/native/path/to/an/icon.png";
location = g_file_new_for_uri (uri);
icon = g_file_icon_new (location);
+
+ g_object_get (icon, "file", &file, NULL);
+ g_assert (file == location);
+ g_object_unref (file);
+
data = g_icon_to_string (icon);
g_assert_cmpstr (data, ==, "/some/native/path/to/an/icon.png");
icon2 = g_icon_new_for_string (data, &error);