Debian Codegraph @

rest-extras/test-runner.c

raw
1 /*
2 * librest - RESTful web services access
3 * Copyright (C) 2009 Intel Corporation.
4 *
5 * This program is free software; you can redistribute it and/or modify it
6 * under the terms and conditions of the GNU Lesser General Public License,
7 * version 2.1, as published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope it will be useful, but WITHOUT ANY
10 * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
11 * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for
12 * more details.
13 *
14 * You should have received a copy of the GNU Lesser General Public License
15 * along with this program; if not, write to the Free Software Foundation,
16 * Inc., 51 Franklin St - Fifth Floor, Boston, MA 02110-1301 USA.
17 */
18
19 #include <config.h>
20 #include <glib-object.h>
21
22 #define test_add(unit_name, func) G_STMT_START { \
23 extern void func (void); \
24 g_test_add_func (unit_name, func); } G_STMT_END
25
26 int
27 main (int argc, char *argv[])
28 {
29 g_test_init (&argc, &argv, NULL);
30
31 test_add ("/flickr/error", test_flickr_error);
32 test_add ("/lastfm/error", test_flickr_error);
33
34 return g_test_run ();
35 }