[gtk+/wip/gbsneto/other-locations: 8/13] tests: add stub test for places view



commit e605e2b8f1134eb050be19d4d20b2a28f0112f47
Author: Georges Basile Stavracas Neto <georges stavracas gmail com>
Date:   Wed Jun 17 07:19:48 2015 -0300

    tests: add stub test for places view

 tests/Makefile.am      |    5 +++++
 tests/testplacesview.c |   24 ++++++++++++++++++++++++
 2 files changed, 29 insertions(+), 0 deletions(-)
---
diff --git a/tests/Makefile.am b/tests/Makefile.am
index 95ac80f..6ae96fe 100644
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@ -105,6 +105,7 @@ noinst_PROGRAMS =  $(TEST_PROGS)    \
        testorientable                  \
        testoverlay                     \
        testoverlaystyleclass           \
+       testplacesview                  \
        testprint                       \
        testrecentchooser               \
        testrecentchoosermenu           \
@@ -251,6 +252,7 @@ testappchooserbutton_DEPENDENCIES = $(TEST_DEPS)
 testorientable_DEPENDENCIES = $(TEST_DEPS)
 testoverlay_DEPENDENCIES = $(TEST_DEPS)
 testoverlaystyleclass_DEPENDENCIES = $(TEST_DEPS)
+testplacesview_DEPENDENCIES = $(TEST_DEPS)
 testprint_DEPENDENCIES = $(TEST_DEPS)
 testrecentchooser_DEPENDENCIES = $(TEST_DEPS)
 testrecentchoosermenu_DEPENDENCIES = $(TEST_DEPS)
@@ -392,6 +394,9 @@ testtoolbar_SOURCES =       \
 testmenubutton_SOURCES =       \
        testmenubutton.c
 
+testplacesview_SOURCES =       \
+       testplacesview.c
+
 testprint_SOURCES =            \
        testprint.c             \
        testprintfileoperation.h \
diff --git a/tests/testplacesview.c b/tests/testplacesview.c
new file mode 100644
index 0000000..89da344
--- /dev/null
+++ b/tests/testplacesview.c
@@ -0,0 +1,24 @@
+#include <gtk/gtk.h>
+
+int
+main (int argc, char *argv[])
+{
+  GtkWidget *win;
+  GtkWidget *view;
+
+  gtk_init (&argc, &argv);
+
+  win = gtk_window_new (GTK_WINDOW_TOPLEVEL);
+  gtk_window_set_default_size (GTK_WINDOW (win), 400, 600);
+
+  view = gtk_places_view_new ();
+
+  gtk_container_add (GTK_CONTAINER (win), view);
+  gtk_widget_show_all (win);
+
+  g_signal_connect (win, "delete-event", G_CALLBACK (gtk_main_quit), win);
+
+  gtk_main ();
+
+  return 0;
+}


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]