GnuCash  2.6.99
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
test-load-backend.c
1 /***************************************************************************
2  * test-load-backend.c
3  *
4  * Replaces the guile version to test the GModule file backend loading.
5  *
6  * Sun Oct 9 18:58:47 2005
7  * Copyright 2005 Neil Williams
9  ****************************************************************************/
10 
11 /*
12  * This program is free software; you can redistribute it and/or modify
13  * it under the terms of the GNU General Public License as published by
14  * the Free Software Foundation; either version 2 of the License, or
15  * (at your option) any later version.
16  *
17  * This program is distributed in the hope that it will be useful,
18  * but WITHOUT ANY WARRANTY; without even the implied warranty of
19  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20  * GNU General Public License for more details.
21  *
22  * You should have received a copy of the GNU General Public License
23  * along with this program; if not, write to the Free Software
24  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
25  * 02110-1301, USA.
26  */
27 
28 #include "config.h"
29 #include "qof.h"
30 #include "cashobjects.h"
31 #include "test-stuff.h"
32 
33 #define GNC_LIB_NAME "gncmod-backend-xml"
34 
35 int main (int argc, char ** argv)
36 {
37  qof_init();
38  cashobjects_register();
39  do_test(
40  qof_load_backend_library ("../.libs/", GNC_LIB_NAME),
41  " loading gnc-backend-xml GModule failed");
42  print_test_results();
43  qof_close();
44  exit(get_rv());
45 }
gboolean qof_load_backend_library(const gchar *directory, const gchar *module_name)
Load a QOF-compatible backend shared library.
void qof_close(void)
Safely close down the Query Object Framework.
void qof_init(void)
Initialise the Query Object Framework.