Revision 1844

trunk/tests/common.h (revision 1844)
1
/*
2
    Copyright (C) 2005-2011  Erik van Pienbroek
3

                
4
    This program is free software; you can redistribute it and/or modify
5
    it under the terms of the GNU General Public License as published by
6
    the Free Software Foundation; either version 2 of the License, or
7
    (at your option) any later version.
8

                
9
    This program is distributed in the hope that it will be useful,
10
    but WITHOUT ANY WARRANTY; without even the implied warranty of
11
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12
    GNU General Public License for more details.
13

                
14
    You should have received a copy of the GNU General Public License
15
    along with this program; if not, write to the Free Software
16
    Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
17
*/
18

                
19
#ifndef _TESTS_COMMON_H_
20
#define _TESTS_COMMON_H_
21

                
22
void initialize_tests(void);
23
void cleanup_tests(void);
24
char *get_location_of_download_queue(void);
25

                
26
#if GLIB_CHECK_VERSION(2,29,4)
27
#define FAIL_TEST(format, args...)      \
28
    g_test_message(format, ## args);    \
29
    g_test_fail();
30
#else
31
#define FAIL_TEST(format, args...)      \
32
    g_error(format, ## args);
33
#endif
34

                
35
#endif /* _TESTS_COMMON_H_ */

Also available in: Unified diff