summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon McVittie <simon.mcvittie@collabora.co.uk>2014-03-20 12:33:22 +0000
committerSimon McVittie <simon.mcvittie@collabora.co.uk>2014-03-25 10:21:05 +0000
commitdb6fa1b7cebd6bc3e782bef5d140b9d7c0291a35 (patch)
treea6d32ec3a4a1e6edbbe983739024ffa3f44752c3
parentd79baa5f8f02a2e3505ac0537283b8a64cc93fb6 (diff)
downloadtelepathy-glib-db6fa1b7cebd6bc3e782bef5d140b9d7c0291a35.tar.gz
fixup previous: util-cxx.cpp: convert to GTest
I missed this one because it doesn't match *.c.
-rw-r--r--tests/util-cxx.cpp32
1 files changed, 30 insertions, 2 deletions
diff --git a/tests/util-cxx.cpp b/tests/util-cxx.cpp
index b8b822e36..42213c08a 100644
--- a/tests/util-cxx.cpp
+++ b/tests/util-cxx.cpp
@@ -23,7 +23,19 @@
#include <gio/gio.h>
#include <telepathy-glib/util.h>
-int main (int argc, char **argv)
+typedef struct {
+ int dummy;
+} Fixture;
+
+extern "C" void
+setup (Fixture *f,
+ gconstpointer data)
+{
+}
+
+extern "C" void
+test (Fixture *f,
+ gconstpointer data)
{
GObject *o;
GHashTable *h;
@@ -36,6 +48,22 @@ int main (int argc, char **argv)
h = g_hash_table_new (NULL, NULL);
tp_clear_boxed (G_TYPE_HASH_TABLE, &h);
+}
+
+extern "C" void
+teardown (Fixture *f,
+ gconstpointer data)
+{
+}
+
+int
+main (int argc,
+ char **argv)
+{
+ g_test_init (&argc, &argv, NULL);
+ g_test_bug_base ("http://bugs.freedesktop.org/show_bug.cgi?id=");
+
+ g_test_add ("/util/cxx", Fixture, NULL, setup, test, teardown);
- return 0;
+ return g_test_run ();
}