summaryrefslogtreecommitdiff
path: root/tests/testglib.c
diff options
context:
space:
mode:
authorMatthias Clasen <mclasen@redhat.com>2007-06-04 14:54:49 +0000
committerMatthias Clasen <matthiasc@src.gnome.org>2007-06-04 14:54:49 +0000
commitd154485bc75ac40665ed810b5669f7a8e7315f3a (patch)
treee28498ed4064d11e631ca008af58340890ea3d92 /tests/testglib.c
parentc68dc0aef515c458d81916cb767d7199a22d6f36 (diff)
Add support for a number of special directories, as defined by the
2007-06-04 Matthias Clasen <mclasen@redhat.com> Add support for a number of special directories, as defined by the xdg-user-dirs specification. (#432651, Bastien Nocera, Emmanuele Bassi, Michael Natterer) * glib/glib.symbols: * glib/gutils.[hc]: Add the GUserDirectory enum and g_get_user_special_dir(), with implementations based on the xdg-user-dirs spec and on native interfaces for Win32 and Carbon. * configure.in: Add Carbon checks. * tests/tetsglib.c: Test g_get_user_special_dir(). svn path=/trunk/; revision=5528
Diffstat (limited to 'tests/testglib.c')
-rw-r--r--tests/testglib.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/tests/testglib.c b/tests/testglib.c
index 0a846653c..9105321fb 100644
--- a/tests/testglib.c
+++ b/tests/testglib.c
@@ -596,6 +596,14 @@ main (int argc,
sv = (gchar **) g_get_language_names ();
g_print ("languages: %s\n", s ? g_strjoinv (":", sv) : "NULL!");
+ /* special dirs */
+ s = g_get_user_special_dir (G_USER_DIRECTORY_DESKTOP);
+ g_print ("user_special[DESKTOP]: %s\n", s ? s : "NULL!");
+ s = g_get_user_special_dir (G_USER_DIRECTORY_DOCUMENTS);
+ g_print ("user_special[DOCUMENTS]: %s\n", s ? s : "NULL!");
+ s = g_get_user_special_dir (G_USER_DIRECTORY_PUBLIC_SHARE);
+ g_print ("user_special[PUBLIC_SHARE]: %s\n", s ? s : "NULL!");
+
/* type sizes */
g_print ("checking size of gint8: %" G_GSIZE_FORMAT, sizeof (gint8));
TEST (NULL, sizeof (gint8) == 1);