aboutsummaryrefslogtreecommitdiffstats
path: root/tests/check-main.c
diff options
context:
space:
mode:
authorXavier Claessens <xclaesse@src.gnome.org>2007-12-29 23:49:28 +0800
committerXavier Claessens <xclaesse@src.gnome.org>2007-12-29 23:49:28 +0800
commit2c4f7c6b6549f8b95845f1838dd0dc710c9e8304 (patch)
tree73f77284e63c07544111aae1cea50f8fced8acf0 /tests/check-main.c
parent876e427bafc95f2f13a333b9bca0d8982b7faf3d (diff)
downloadgsoc2013-empathy-2c4f7c6b6549f8b95845f1838dd0dc710c9e8304.tar
gsoc2013-empathy-2c4f7c6b6549f8b95845f1838dd0dc710c9e8304.tar.gz
gsoc2013-empathy-2c4f7c6b6549f8b95845f1838dd0dc710c9e8304.tar.bz2
gsoc2013-empathy-2c4f7c6b6549f8b95845f1838dd0dc710c9e8304.tar.lz
gsoc2013-empathy-2c4f7c6b6549f8b95845f1838dd0dc710c9e8304.tar.xz
gsoc2013-empathy-2c4f7c6b6549f8b95845f1838dd0dc710c9e8304.tar.zst
gsoc2013-empathy-2c4f7c6b6549f8b95845f1838dd0dc710c9e8304.zip
Add "check" framework support. Fixes bug #505622 (Guillaume Desmottes).
svn path=/trunk/; revision=509
Diffstat (limited to 'tests/check-main.c')
-rw-r--r--tests/check-main.c40
1 files changed, 40 insertions, 0 deletions
diff --git a/tests/check-main.c b/tests/check-main.c
new file mode 100644
index 000000000..6dcfe3237
--- /dev/null
+++ b/tests/check-main.c
@@ -0,0 +1,40 @@
+#include <stdlib.h>
+#include <stdio.h>
+#include <string.h>
+#include <glib-object.h>
+
+#include <check.h>
+
+#include "check-helpers.h"
+#include "check-libempathy.h"
+
+#include "config.h"
+
+static Suite *
+make_libempathy_suite (void)
+{
+ Suite *s = suite_create ("libempathy");
+
+ suite_add_tcase (s, make_empathy_utils_tcase ());
+
+ return s;
+}
+
+int
+main (void)
+{
+ int number_failed = 0;
+ Suite *s;
+ SRunner *sr;
+
+ check_helpers_init ();
+ g_type_init ();
+
+ s = make_libempathy_suite ();
+ sr = srunner_create (s);
+ srunner_run_all (sr, CK_NORMAL);
+ number_failed += srunner_ntests_failed (sr);
+ srunner_free (sr);
+
+ return (number_failed == 0) ? EXIT_SUCCESS : EXIT_FAILURE;
+}