summaryrefslogtreecommitdiff
path: root/gdk
diff options
context:
space:
mode:
authorSven Herzberg <sven@imendio.com>2008-08-15 18:57:31 +0000
committerSven Herzberg <herzi@src.gnome.org>2008-08-15 18:57:31 +0000
commite8442a52aa6659a1aabd172ccbe00be9fdb09fdc (patch)
treee02643c3aec97262f25a17951eb9735dee115e61 /gdk
parentefb330447c337a8e325fa561a178fd7c476ea182 (diff)
downloadgtk+-e8442a52aa6659a1aabd172ccbe00be9fdb09fdc.tar.gz
Use the g_test_*() API for this test reviewed by: Richard Hult
2008-08-15 Sven Herzberg <sven@imendio.com> Use the g_test_*() API for this test reviewed by: Richard Hult * gdk/tests/check-gdk-cairo.c: use the g_test_*() API to permit adding new tests svn path=/trunk/; revision=21133
Diffstat (limited to 'gdk')
-rw-r--r--gdk/tests/check-gdk-cairo.c20
1 files changed, 14 insertions, 6 deletions
diff --git a/gdk/tests/check-gdk-cairo.c b/gdk/tests/check-gdk-cairo.c
index 5a0307b989..a89724e0c1 100644
--- a/gdk/tests/check-gdk-cairo.c
+++ b/gdk/tests/check-gdk-cairo.c
@@ -46,9 +46,8 @@ test (cairo_t* cr)
cairo_stroke (cr);
}
-int
-main (int argc,
- char**argv)
+static void
+test_pixmap_orientation (void)
{
GdkPixmap* pixmap;
GdkPixbuf* pixbuf;
@@ -61,8 +60,6 @@ main (int argc,
guchar* data_imagesrf;
guint i;
- gdk_init (&argc, &argv);
-
/* create "platform.png" via GdkPixmap */
pixmap = gdk_pixmap_new (NULL /* drawable */, 100 /* w */, 80 /* h */, 24 /* d */);
cr = gdk_cairo_create (pixmap);
@@ -133,7 +130,18 @@ main (int argc,
g_unlink ("gdksurface.png");
g_unlink ("cairosurface.png");
+}
+
+int
+main (int argc,
+ char**argv)
+{
+ g_test_init (&argc, &argv, NULL);
+ gdk_init (&argc, &argv);
+
+ g_test_add_func ("/gdk/pixmap/orientation",
+ test_pixmap_orientation);
- return 0;
+ return g_test_run ();
}