Initial commit
[platform/upstream/glib2.0.git] / docs / reference / glib / html / glib-Testing.html
1 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
2 <html>
3 <head>
4 <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
5 <title>Testing</title>
6 <meta name="generator" content="DocBook XSL Stylesheets V1.75.2">
7 <link rel="home" href="index.html" title="GLib Reference Manual">
8 <link rel="up" href="glib-utilities.html" title="GLib Utilities">
9 <link rel="prev" href="glib-Bookmark-file-parser.html" title="Bookmark file parser">
10 <link rel="next" href="glib-Windows-Compatibility-Functions.html" title="Windows Compatibility Functions">
11 <meta name="generator" content="GTK-Doc V1.13 (XML mode)">
12 <link rel="stylesheet" href="style.css" type="text/css">
13 <link rel="chapter" href="glib.html" title="GLib Overview">
14 <link rel="chapter" href="glib-fundamentals.html" title="GLib Fundamentals">
15 <link rel="chapter" href="glib-core.html" title="GLib Core Application Support">
16 <link rel="chapter" href="glib-utilities.html" title="GLib Utilities">
17 <link rel="chapter" href="glib-data-types.html" title="GLib Data Types">
18 <link rel="chapter" href="tools.html" title="GLib Tools">
19 <link rel="index" href="api-index-full.html" title="Index">
20 <link rel="index" href="api-index-deprecated.html" title="Index of deprecated symbols">
21 <link rel="index" href="api-index-2-2.html" title="Index of new symbols in 2.2">
22 <link rel="index" href="api-index-2-4.html" title="Index of new symbols in 2.4">
23 <link rel="index" href="api-index-2-6.html" title="Index of new symbols in 2.6">
24 <link rel="index" href="api-index-2-8.html" title="Index of new symbols in 2.8">
25 <link rel="index" href="api-index-2-10.html" title="Index of new symbols in 2.10">
26 <link rel="index" href="api-index-2-12.html" title="Index of new symbols in 2.12">
27 <link rel="index" href="api-index-2-14.html" title="Index of new symbols in 2.14">
28 <link rel="index" href="api-index-2-16.html" title="Index of new symbols in 2.16">
29 <link rel="index" href="api-index-2-18.html" title="Index of new symbols in 2.18">
30 <link rel="index" href="api-index-2-20.html" title="Index of new symbols in 2.20">
31 <link rel="index" href="api-index-2-22.html" title="Index of new symbols in 2.22">
32 <link rel="index" href="api-index-2-24.html" title="Index of new symbols in 2.24">
33 </head>
34 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
35 <table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="2">
36 <tr valign="middle">
37 <td><a accesskey="p" href="glib-Bookmark-file-parser.html"><img src="left.png" width="24" height="24" border="0" alt="Prev"></a></td>
38 <td><a accesskey="u" href="glib-utilities.html"><img src="up.png" width="24" height="24" border="0" alt="Up"></a></td>
39 <td><a accesskey="h" href="index.html"><img src="home.png" width="24" height="24" border="0" alt="Home"></a></td>
40 <th width="100%" align="center">GLib Reference Manual</th>
41 <td><a accesskey="n" href="glib-Windows-Compatibility-Functions.html"><img src="right.png" width="24" height="24" border="0" alt="Next"></a></td>
42 </tr>
43 <tr><td colspan="5" class="shortcuts">
44 <a href="#glib-Testing.synopsis" class="shortcut">Top</a>
45                    | 
46                   <a href="#glib-Testing.description" class="shortcut">Description</a>
47 </td></tr>
48 </table>
49 <div class="refentry" title="Testing">
50 <a name="glib-Testing"></a><div class="titlepage"></div>
51 <div class="refnamediv"><table width="100%"><tr>
52 <td valign="top">
53 <h2><span class="refentrytitle"><a name="glib-Testing.top_of_page"></a>Testing</span></h2>
54 <p>Testing — a test framework</p>
55 </td>
56 <td valign="top" align="right"></td>
57 </tr></table></div>
58 <div class="refsynopsisdiv" title="Synopsis">
59 <a name="glib-Testing.synopsis"></a><h2>Synopsis</h2>
60 <pre class="synopsis">
61 #include &lt;glib.h&gt;
62
63 <span class="returnvalue">void</span>                <a class="link" href="glib-Testing.html#g-test-minimized-result" title="g_test_minimized_result ()">g_test_minimized_result</a>             (<span class="returnvalue">double</span> minimized_quantity,
64                                                          const <span class="returnvalue">char</span> *format,
65                                                          ...);
66 <span class="returnvalue">void</span>                <a class="link" href="glib-Testing.html#g-test-maximized-result" title="g_test_maximized_result ()">g_test_maximized_result</a>             (<span class="returnvalue">double</span> maximized_quantity,
67                                                          const <span class="returnvalue">char</span> *format,
68                                                          ...);
69 <span class="returnvalue">void</span>                <a class="link" href="glib-Testing.html#g-test-init" title="g_test_init ()">g_test_init</a>                         (<span class="returnvalue">int</span> *argc,
70                                                          <span class="returnvalue">char</span> ***argv,
71                                                          ...);
72 #define             <a class="link" href="glib-Testing.html#g-test-quick" title="g_test_quick()">g_test_quick</a>                        ()
73 #define             <a class="link" href="glib-Testing.html#g-test-slow" title="g_test_slow()">g_test_slow</a>                         ()
74 #define             <a class="link" href="glib-Testing.html#g-test-thorough" title="g_test_thorough()">g_test_thorough</a>                     ()
75 #define             <a class="link" href="glib-Testing.html#g-test-perf" title="g_test_perf()">g_test_perf</a>                         ()
76 #define             <a class="link" href="glib-Testing.html#g-test-verbose" title="g_test_verbose()">g_test_verbose</a>                      ()
77 #define             <a class="link" href="glib-Testing.html#g-test-quiet" title="g_test_quiet()">g_test_quiet</a>                        ()
78 <span class="returnvalue">int</span>                 <a class="link" href="glib-Testing.html#g-test-run" title="g_test_run ()">g_test_run</a>                          (void);
79 <span class="returnvalue">void</span>                <a class="link" href="glib-Testing.html#g-test-add-func" title="g_test_add_func ()">g_test_add_func</a>                     (const <span class="returnvalue">char</span> *testpath,
80                                                          <span class="returnvalue">void</span> (test_funcvoid) ());
81 <span class="returnvalue">void</span>                <a class="link" href="glib-Testing.html#g-test-add-data-func" title="g_test_add_data_func ()">g_test_add_data_func</a>                (const <span class="returnvalue">char</span> *testpath,
82                                                          <a class="link" href="glib-Basic-Types.html#gconstpointer" title="gconstpointer"><span class="returnvalue">gconstpointer</span></a> test_data,
83                                                          <span class="returnvalue">void</span> (test_funcgconstpointer) ());
84 #define             <a class="link" href="glib-Testing.html#g-test-add" title="g_test_add()">g_test_add</a>                          (testpath, Fixture, tdata, fsetup, ftest, fteardown)
85 <span class="returnvalue">void</span>                <a class="link" href="glib-Testing.html#g-test-message" title="g_test_message ()">g_test_message</a>                      (const <span class="returnvalue">char</span> *format,
86                                                          ...);
87 <span class="returnvalue">void</span>                <a class="link" href="glib-Testing.html#g-test-bug-base" title="g_test_bug_base ()">g_test_bug_base</a>                     (const <span class="returnvalue">char</span> *uri_pattern);
88 <span class="returnvalue">void</span>                <a class="link" href="glib-Testing.html#g-test-bug" title="g_test_bug ()">g_test_bug</a>                          (const <span class="returnvalue">char</span> *bug_uri_snippet);
89 <a class="link" href="glib-Basic-Types.html#gboolean" title="gboolean"><span class="returnvalue">gboolean</span></a>            (<a class="link" href="glib-Testing.html#GTestLogFatalFunc" title="GTestLogFatalFunc ()">*GTestLogFatalFunc</a>)                (const <a class="link" href="glib-Basic-Types.html#gchar" title="gchar"><span class="returnvalue">gchar</span></a> *log_domain,
90                                                          <a class="link" href="glib-Message-Logging.html#GLogLevelFlags" title="enum GLogLevelFlags"><span class="returnvalue">GLogLevelFlags</span></a> log_level,
91                                                          const <a class="link" href="glib-Basic-Types.html#gchar" title="gchar"><span class="returnvalue">gchar</span></a> *message,
92                                                          <a class="link" href="glib-Basic-Types.html#gpointer" title="gpointer"><span class="returnvalue">gpointer</span></a> user_data);
93 <span class="returnvalue">void</span>                <a class="link" href="glib-Testing.html#g-test-log-set-fatal-handler" title="g_test_log_set_fatal_handler ()">g_test_log_set_fatal_handler</a>        (<a class="link" href="glib-Testing.html#GTestLogFatalFunc" title="GTestLogFatalFunc ()"><span class="returnvalue">GTestLogFatalFunc</span></a> log_func,
94                                                          <a class="link" href="glib-Basic-Types.html#gpointer" title="gpointer"><span class="returnvalue">gpointer</span></a> user_data);
95 <span class="returnvalue">void</span>                <a class="link" href="glib-Testing.html#g-test-timer-start" title="g_test_timer_start ()">g_test_timer_start</a>                  (void);
96 <span class="returnvalue">double</span>              <a class="link" href="glib-Testing.html#g-test-timer-elapsed" title="g_test_timer_elapsed ()">g_test_timer_elapsed</a>                (void);
97 <span class="returnvalue">double</span>              <a class="link" href="glib-Testing.html#g-test-timer-last" title="g_test_timer_last ()">g_test_timer_last</a>                   (void);
98 <span class="returnvalue">void</span>                <a class="link" href="glib-Testing.html#g-test-queue-free" title="g_test_queue_free ()">g_test_queue_free</a>                   (<a class="link" href="glib-Basic-Types.html#gpointer" title="gpointer"><span class="returnvalue">gpointer</span></a> gfree_pointer);
99 <span class="returnvalue">void</span>                <a class="link" href="glib-Testing.html#g-test-queue-destroy" title="g_test_queue_destroy ()">g_test_queue_destroy</a>                (<a class="link" href="glib-Datasets.html#GDestroyNotify" title="GDestroyNotify ()"><span class="returnvalue">GDestroyNotify</span></a> destroy_func,
100                                                          <a class="link" href="glib-Basic-Types.html#gpointer" title="gpointer"><span class="returnvalue">gpointer</span></a> destroy_data);
101 #define             <a class="link" href="glib-Testing.html#g-test-queue-unref" title="g_test_queue_unref()">g_test_queue_unref</a>                  (gobject)
102 enum                <a class="link" href="glib-Testing.html#GTestTrapFlags" title="enum GTestTrapFlags">GTestTrapFlags</a>;
103 <a class="link" href="glib-Basic-Types.html#gboolean" title="gboolean"><span class="returnvalue">gboolean</span></a>            <a class="link" href="glib-Testing.html#g-test-trap-fork" title="g_test_trap_fork ()">g_test_trap_fork</a>                    (<a class="link" href="glib-Basic-Types.html#guint64" title="guint64"><span class="returnvalue">guint64</span></a> usec_timeout,
104                                                          <a class="link" href="glib-Testing.html#GTestTrapFlags" title="enum GTestTrapFlags"><span class="returnvalue">GTestTrapFlags</span></a> test_trap_flags);
105 <a class="link" href="glib-Basic-Types.html#gboolean" title="gboolean"><span class="returnvalue">gboolean</span></a>            <a class="link" href="glib-Testing.html#g-test-trap-has-passed" title="g_test_trap_has_passed ()">g_test_trap_has_passed</a>              (void);
106 <a class="link" href="glib-Basic-Types.html#gboolean" title="gboolean"><span class="returnvalue">gboolean</span></a>            <a class="link" href="glib-Testing.html#g-test-trap-reached-timeout" title="g_test_trap_reached_timeout ()">g_test_trap_reached_timeout</a>         (void);
107 #define             <a class="link" href="glib-Testing.html#g-test-trap-assert-passed" title="g_test_trap_assert_passed()">g_test_trap_assert_passed</a>           ()
108 #define             <a class="link" href="glib-Testing.html#g-test-trap-assert-failed" title="g_test_trap_assert_failed()">g_test_trap_assert_failed</a>           ()
109 #define             <a class="link" href="glib-Testing.html#g-test-trap-assert-stdout" title="g_test_trap_assert_stdout()">g_test_trap_assert_stdout</a>           (soutpattern)
110 #define             <a class="link" href="glib-Testing.html#g-test-trap-assert-stdout-unmatched" title="g_test_trap_assert_stdout_unmatched()">g_test_trap_assert_stdout_unmatched</a> (soutpattern)
111 #define             <a class="link" href="glib-Testing.html#g-test-trap-assert-stderr" title="g_test_trap_assert_stderr()">g_test_trap_assert_stderr</a>           (serrpattern)
112 #define             <a class="link" href="glib-Testing.html#g-test-trap-assert-stderr-unmatched" title="g_test_trap_assert_stderr_unmatched()">g_test_trap_assert_stderr_unmatched</a> (serrpattern)
113 #define             <a class="link" href="glib-Testing.html#g-test-rand-bit" title="g_test_rand_bit()">g_test_rand_bit</a>                     ()
114 <a class="link" href="glib-Basic-Types.html#gint32" title="gint32"><span class="returnvalue">gint32</span></a>              <a class="link" href="glib-Testing.html#g-test-rand-int" title="g_test_rand_int ()">g_test_rand_int</a>                     (void);
115 <a class="link" href="glib-Basic-Types.html#gint32" title="gint32"><span class="returnvalue">gint32</span></a>              <a class="link" href="glib-Testing.html#g-test-rand-int-range" title="g_test_rand_int_range ()">g_test_rand_int_range</a>               (<a class="link" href="glib-Basic-Types.html#gint32" title="gint32"><span class="returnvalue">gint32</span></a> begin,
116                                                          <a class="link" href="glib-Basic-Types.html#gint32" title="gint32"><span class="returnvalue">gint32</span></a> end);
117 <span class="returnvalue">double</span>              <a class="link" href="glib-Testing.html#g-test-rand-double" title="g_test_rand_double ()">g_test_rand_double</a>                  (void);
118 <span class="returnvalue">double</span>              <a class="link" href="glib-Testing.html#g-test-rand-double-range" title="g_test_rand_double_range ()">g_test_rand_double_range</a>            (<span class="returnvalue">double</span> range_start,
119                                                          <span class="returnvalue">double</span> range_end);
120 #define             <a class="link" href="glib-Testing.html#g-assert" title="g_assert()">g_assert</a>                            (expr)
121 #define             <a class="link" href="glib-Testing.html#g-assert-not-reached" title="g_assert_not_reached()">g_assert_not_reached</a>                ()
122 #define             <a class="link" href="glib-Testing.html#g-assert-cmpstr" title="g_assert_cmpstr()">g_assert_cmpstr</a>                     (s1, cmp, s2)
123 #define             <a class="link" href="glib-Testing.html#g-assert-cmpint" title="g_assert_cmpint()">g_assert_cmpint</a>                     (n1, cmp, n2)
124 #define             <a class="link" href="glib-Testing.html#g-assert-cmpuint" title="g_assert_cmpuint()">g_assert_cmpuint</a>                    (n1, cmp, n2)
125 #define             <a class="link" href="glib-Testing.html#g-assert-cmphex" title="g_assert_cmphex()">g_assert_cmphex</a>                     (n1, cmp, n2)
126 #define             <a class="link" href="glib-Testing.html#g-assert-cmpfloat" title="g_assert_cmpfloat()">g_assert_cmpfloat</a>                   (n1,cmp,n2)
127 #define             <a class="link" href="glib-Testing.html#g-assert-no-error" title="g_assert_no_error()">g_assert_no_error</a>                   (err)
128 #define             <a class="link" href="glib-Testing.html#g-assert-error" title="g_assert_error()">g_assert_error</a>                      (err, dom, c)
129 typedef             <a class="link" href="glib-Testing.html#GTestCase" title="GTestCase">GTestCase</a>;
130 typedef             <a class="link" href="glib-Testing.html#GTestSuite" title="GTestSuite">GTestSuite</a>;
131 <a class="link" href="glib-Testing.html#GTestCase" title="GTestCase"><span class="returnvalue">GTestCase</span></a>*          <a class="link" href="glib-Testing.html#g-test-create-case" title="g_test_create_case ()">g_test_create_case</a>                  (const <span class="returnvalue">char</span> *test_name,
132                                                          <a class="link" href="glib-Basic-Types.html#gsize" title="gsize"><span class="returnvalue">gsize</span></a> data_size,
133                                                          <a class="link" href="glib-Basic-Types.html#gconstpointer" title="gconstpointer"><span class="returnvalue">gconstpointer</span></a> test_data,
134                                                          <span class="returnvalue">void</span> (data_setupvoid) (),
135                                                          <span class="returnvalue">void</span> (data_testvoid) (),
136                                                          <span class="returnvalue">void</span> (data_teardownvoid) ());
137 <a class="link" href="glib-Testing.html#GTestSuite" title="GTestSuite"><span class="returnvalue">GTestSuite</span></a>*         <a class="link" href="glib-Testing.html#g-test-create-suite" title="g_test_create_suite ()">g_test_create_suite</a>                 (const <span class="returnvalue">char</span> *suite_name);
138 <a class="link" href="glib-Testing.html#GTestSuite" title="GTestSuite"><span class="returnvalue">GTestSuite</span></a>*         <a class="link" href="glib-Testing.html#g-test-get-root" title="g_test_get_root ()">g_test_get_root</a>                     (void);
139 <span class="returnvalue">void</span>                <a class="link" href="glib-Testing.html#g-test-suite-add" title="g_test_suite_add ()">g_test_suite_add</a>                    (<a class="link" href="glib-Testing.html#GTestSuite" title="GTestSuite"><span class="returnvalue">GTestSuite</span></a> *suite,
140                                                          <a class="link" href="glib-Testing.html#GTestCase" title="GTestCase"><span class="returnvalue">GTestCase</span></a> *test_case);
141 <span class="returnvalue">void</span>                <a class="link" href="glib-Testing.html#g-test-suite-add-suite" title="g_test_suite_add_suite ()">g_test_suite_add_suite</a>              (<a class="link" href="glib-Testing.html#GTestSuite" title="GTestSuite"><span class="returnvalue">GTestSuite</span></a> *suite,
142                                                          <a class="link" href="glib-Testing.html#GTestSuite" title="GTestSuite"><span class="returnvalue">GTestSuite</span></a> *nestedsuite);
143 <span class="returnvalue">int</span>                 <a class="link" href="glib-Testing.html#g-test-run-suite" title="g_test_run_suite ()">g_test_run_suite</a>                    (<a class="link" href="glib-Testing.html#GTestSuite" title="GTestSuite"><span class="returnvalue">GTestSuite</span></a> *suite);
144 </pre>
145 </div>
146 <div class="refsect1" title="Description">
147 <a name="glib-Testing.description"></a><h2>Description</h2>
148 <p>
149 GLib provides a framework for writing and maintaining unit tests
150 in parallel to the code they are testing. The API is designed according
151 to established concepts found in the other test frameworks (JUnit, NUnit,
152 RUnit), which in turn is based on smalltalk unit testing concepts.
153 </p>
154 <div class="variablelist"><table border="0">
155 <col align="left" valign="top">
156 <tbody>
157 <tr>
158 <td><p><span class="term">Test case</span></p></td>
159 <td><p>
160       Tests (test methods) are grouped together with their
161       fixture into test cases.
162     </p></td>
163 </tr>
164 <tr>
165 <td><p><span class="term">Fixture</span></p></td>
166 <td><p>
167       A test fixture consists of fixture data and setup and teardown methods
168       to establish the environment for the test functions. We use fresh
169       fixtures, i.e. fixtures are newly set up and torn down around each test
170       invocation to avoid dependencies between tests.
171     </p></td>
172 </tr>
173 <tr>
174 <td><p><span class="term">Test suite</span></p></td>
175 <td><p>
176       Test cases can be grouped into test suites, to allow subsets of the
177       available tests to be run. Test suites can be grouped into other test
178       suites as well.
179     </p></td>
180 </tr>
181 </tbody>
182 </table></div>
183 <p>
184 The API is designed to handle creation and registration of test suites and
185 test cases implicitly. A simple call like
186 </p>
187 <div class="informalexample"><pre class="programlisting">
188   g_test_add_func ("/misc/assertions", test_assertions);
189 </pre></div>
190 <p>
191 creates a test suite called "misc" with a single test case named "assertions",
192 which consists of running the test_assertions function.
193 </p>
194 <p>
195 In addition to the traditional <a class="link" href="glib-Testing.html#g-assert" title="g_assert()"><code class="function">g_assert()</code></a>, the test framework provides
196 an extended set of assertions for string and numerical comparisons:
197 <a class="link" href="glib-Testing.html#g-assert-cmpfloat" title="g_assert_cmpfloat()"><code class="function">g_assert_cmpfloat()</code></a>, <a class="link" href="glib-Testing.html#g-assert-cmpint" title="g_assert_cmpint()"><code class="function">g_assert_cmpint()</code></a>, <a class="link" href="glib-Testing.html#g-assert-cmpuint" title="g_assert_cmpuint()"><code class="function">g_assert_cmpuint()</code></a>, <a class="link" href="glib-Testing.html#g-assert-cmphex" title="g_assert_cmphex()"><code class="function">g_assert_cmphex()</code></a>,
198 <a class="link" href="glib-Testing.html#g-assert-cmpstr" title="g_assert_cmpstr()"><code class="function">g_assert_cmpstr()</code></a>. The advantage of these variants over plain <a class="link" href="glib-Testing.html#g-assert" title="g_assert()"><code class="function">g_assert()</code></a>
199 is that the assertion messages can be more elaborate, and include the
200 values of the compared entities.
201 </p>
202 <p>
203 GLib ships with two utilities called gtester and gtester-report to
204 facilitate running tests and producing nicely formatted test reports.
205 </p>
206 </div>
207 <div class="refsect1" title="Details">
208 <a name="glib-Testing.details"></a><h2>Details</h2>
209 <div class="refsect2" title="g_test_minimized_result ()">
210 <a name="g-test-minimized-result"></a><h3>g_test_minimized_result ()</h3>
211 <pre class="programlisting"><span class="returnvalue">void</span>                g_test_minimized_result             (<span class="returnvalue">double</span> minimized_quantity,
212                                                          const <span class="returnvalue">char</span> *format,
213                                                          ...);</pre>
214 <p>
215 Report the result of a performance or measurement test.
216 The test should generally strive to minimize the reported
217 quantities (smaller values are better than larger ones),
218 this and <em class="parameter"><code>minimized_quantity</code></em> can determine sorting
219 order for test result reports.</p>
220 <div class="variablelist"><table border="0">
221 <col align="left" valign="top">
222 <tbody>
223 <tr>
224 <td><p><span class="term"><em class="parameter"><code>minimized_quantity</code></em> :</span></p></td>
225 <td> the reported value
226 </td>
227 </tr>
228 <tr>
229 <td><p><span class="term"><em class="parameter"><code>format</code></em> :</span></p></td>
230 <td> the format string of the report message
231 </td>
232 </tr>
233 <tr>
234 <td><p><span class="term"><em class="parameter"><code>...</code></em> :</span></p></td>
235 <td> arguments to pass to the <code class="function">printf()</code> function
236 </td>
237 </tr>
238 </tbody>
239 </table></div>
240 <p class="since">Since 2.16</p>
241 </div>
242 <hr>
243 <div class="refsect2" title="g_test_maximized_result ()">
244 <a name="g-test-maximized-result"></a><h3>g_test_maximized_result ()</h3>
245 <pre class="programlisting"><span class="returnvalue">void</span>                g_test_maximized_result             (<span class="returnvalue">double</span> maximized_quantity,
246                                                          const <span class="returnvalue">char</span> *format,
247                                                          ...);</pre>
248 <p>
249 Report the result of a performance or measurement test.
250 The test should generally strive to maximize the reported
251 quantities (larger values are better than smaller ones),
252 this and <em class="parameter"><code>maximized_quantity</code></em> can determine sorting
253 order for test result reports.</p>
254 <div class="variablelist"><table border="0">
255 <col align="left" valign="top">
256 <tbody>
257 <tr>
258 <td><p><span class="term"><em class="parameter"><code>maximized_quantity</code></em> :</span></p></td>
259 <td> the reported value
260 </td>
261 </tr>
262 <tr>
263 <td><p><span class="term"><em class="parameter"><code>format</code></em> :</span></p></td>
264 <td> the format string of the report message
265 </td>
266 </tr>
267 <tr>
268 <td><p><span class="term"><em class="parameter"><code>...</code></em> :</span></p></td>
269 <td> arguments to pass to the <code class="function">printf()</code> function
270 </td>
271 </tr>
272 </tbody>
273 </table></div>
274 <p class="since">Since 2.16</p>
275 </div>
276 <hr>
277 <div class="refsect2" title="g_test_init ()">
278 <a name="g-test-init"></a><h3>g_test_init ()</h3>
279 <pre class="programlisting"><span class="returnvalue">void</span>                g_test_init                         (<span class="returnvalue">int</span> *argc,
280                                                          <span class="returnvalue">char</span> ***argv,
281                                                          ...);</pre>
282 <p>
283 Initialize the GLib testing framework, e.g. by seeding the
284 test random number generator, the name for <a class="link" href="glib-Miscellaneous-Utility-Functions.html#g-get-prgname" title="g_get_prgname ()"><code class="function">g_get_prgname()</code></a>
285 and parsing test related command line args.
286 So far, the following arguments are understood:
287 </p>
288 <div class="variablelist"><table border="0">
289 <col align="left" valign="top">
290 <tbody>
291 <tr>
292 <td><p><span class="term"><code class="option">-l</code></span></p></td>
293 <td><p>
294       list test cases available in a test executable.
295     </p></td>
296 </tr>
297 <tr>
298 <td><p><span class="term"><code class="option">--seed=<em class="replaceable"><code>RANDOMSEED</code></em></code></span></p></td>
299 <td><p>
300       provide a random seed to reproduce test runs using random numbers.
301     </p></td>
302 </tr>
303 <tr>
304 <td><p><span class="term"><code class="option">--verbose</code></span></p></td>
305 <td><p>run tests verbosely.</p></td>
306 </tr>
307 <tr>
308 <td><p><span class="term"><code class="option">-q</code>, <code class="option">--quiet</code></span></p></td>
309 <td><p>run tests quietly.</p></td>
310 </tr>
311 <tr>
312 <td><p><span class="term"><code class="option">-p <em class="replaceable"><code>TESTPATH</code></em></code></span></p></td>
313 <td><p>
314         execute all tests matching <em class="replaceable"><code>TESTPATH</code></em>.
315       </p></td>
316 </tr>
317 <tr>
318 <td><p><span class="term"><code class="option">-m {perf|slow|thorough|quick}</code></span></p></td>
319 <td>
320 <p>
321         execute tests according to these test modes:
322         </p>
323 <div class="variablelist"><table border="0">
324 <col align="left" valign="top">
325 <tbody>
326 <tr>
327 <td><p><span class="term">perf</span></p></td>
328 <td><p>
329               performance tests, may take long and report results.
330             </p></td>
331 </tr>
332 <tr>
333 <td><p><span class="term">slow, thorough</span></p></td>
334 <td><p>
335               slow and thorough tests, may take quite long and 
336               maximize coverage.
337             </p></td>
338 </tr>
339 <tr>
340 <td><p><span class="term">quick</span></p></td>
341 <td><p>
342               quick tests, should run really quickly and give good coverage.
343             </p></td>
344 </tr>
345 </tbody>
346 </table></div>
347 <p>
348       </p>
349 </td>
350 </tr>
351 <tr>
352 <td><p><span class="term"><code class="option">--debug-log</code></span></p></td>
353 <td><p>debug test logging output.</p></td>
354 </tr>
355 <tr>
356 <td><p><span class="term"><code class="option">-k</code>, <code class="option">--keep-going</code></span></p></td>
357 <td><p>gtester-specific argument.</p></td>
358 </tr>
359 <tr>
360 <td><p><span class="term"><code class="option">--GTestLogFD <em class="replaceable"><code>N</code></em></code></span></p></td>
361 <td><p>gtester-specific argument.</p></td>
362 </tr>
363 <tr>
364 <td><p><span class="term"><code class="option">--GTestSkipCount <em class="replaceable"><code>N</code></em></code></span></p></td>
365 <td><p>gtester-specific argument.</p></td>
366 </tr>
367 </tbody>
368 </table></div>
369 <div class="variablelist"><table border="0">
370 <col align="left" valign="top">
371 <tbody>
372 <tr>
373 <td><p><span class="term"><em class="parameter"><code>argc</code></em> :</span></p></td>
374 <td> Address of the <em class="parameter"><code>argc</code></em> parameter of the <code class="function">main()</code> function.
375        Changed if any arguments were handled.
376 </td>
377 </tr>
378 <tr>
379 <td><p><span class="term"><em class="parameter"><code>argv</code></em> :</span></p></td>
380 <td> Address of the <em class="parameter"><code>argv</code></em> parameter of <code class="function">main()</code>.
381        Any parameters understood by <a class="link" href="glib-Testing.html#g-test-init" title="g_test_init ()"><code class="function">g_test_init()</code></a> stripped before return.
382 </td>
383 </tr>
384 <tr>
385 <td><p><span class="term"><em class="parameter"><code>...</code></em> :</span></p></td>
386 <td> Reserved for future extension. Currently, you must pass <a class="link" href="glib-Standard-Macros.html#NULL:CAPS" title="NULL"><code class="literal">NULL</code></a>.
387 </td>
388 </tr>
389 </tbody>
390 </table></div>
391 <p class="since">Since 2.16</p>
392 </div>
393 <hr>
394 <div class="refsect2" title="g_test_quick()">
395 <a name="g-test-quick"></a><h3>g_test_quick()</h3>
396 <pre class="programlisting">#define             g_test_quick()</pre>
397 <p>
398 Returns <a class="link" href="glib-Standard-Macros.html#TRUE:CAPS" title="TRUE"><code class="literal">TRUE</code></a> if tests are run in quick mode.
399 </p>
400 </div>
401 <hr>
402 <div class="refsect2" title="g_test_slow()">
403 <a name="g-test-slow"></a><h3>g_test_slow()</h3>
404 <pre class="programlisting">#define             g_test_slow()</pre>
405 <p>
406 Returns <a class="link" href="glib-Standard-Macros.html#TRUE:CAPS" title="TRUE"><code class="literal">TRUE</code></a> if tests are run in slow mode.
407 </p>
408 </div>
409 <hr>
410 <div class="refsect2" title="g_test_thorough()">
411 <a name="g-test-thorough"></a><h3>g_test_thorough()</h3>
412 <pre class="programlisting">#define             g_test_thorough()</pre>
413 <p>
414 Returns <a class="link" href="glib-Standard-Macros.html#TRUE:CAPS" title="TRUE"><code class="literal">TRUE</code></a> if tests are run in thorough mode.
415 </p>
416 </div>
417 <hr>
418 <div class="refsect2" title="g_test_perf()">
419 <a name="g-test-perf"></a><h3>g_test_perf()</h3>
420 <pre class="programlisting">#define             g_test_perf()</pre>
421 <p>
422 Returns <a class="link" href="glib-Standard-Macros.html#TRUE:CAPS" title="TRUE"><code class="literal">TRUE</code></a> if tests are run in performance mode.
423 </p>
424 </div>
425 <hr>
426 <div class="refsect2" title="g_test_verbose()">
427 <a name="g-test-verbose"></a><h3>g_test_verbose()</h3>
428 <pre class="programlisting">#define             g_test_verbose()</pre>
429 <p>
430 Returns <a class="link" href="glib-Standard-Macros.html#TRUE:CAPS" title="TRUE"><code class="literal">TRUE</code></a> if tests are run in verbose mode.
431 </p>
432 </div>
433 <hr>
434 <div class="refsect2" title="g_test_quiet()">
435 <a name="g-test-quiet"></a><h3>g_test_quiet()</h3>
436 <pre class="programlisting">#define             g_test_quiet()</pre>
437 <p>
438 Returns <a class="link" href="glib-Standard-Macros.html#TRUE:CAPS" title="TRUE"><code class="literal">TRUE</code></a> if tests are run in quiet mode.
439 </p>
440 </div>
441 <hr>
442 <div class="refsect2" title="g_test_run ()">
443 <a name="g-test-run"></a><h3>g_test_run ()</h3>
444 <pre class="programlisting"><span class="returnvalue">int</span>                 g_test_run                          (void);</pre>
445 <p>
446 Runs all tests under the toplevel suite which can be retrieved
447 with <a class="link" href="glib-Testing.html#g-test-get-root" title="g_test_get_root ()"><code class="function">g_test_get_root()</code></a>. Similar to <a class="link" href="glib-Testing.html#g-test-run-suite" title="g_test_run_suite ()"><code class="function">g_test_run_suite()</code></a>, the test
448 cases to be run are filtered according to
449 test path arguments (-p <em class="replaceable"><code>testpath</code></em>) as 
450 parsed by <a class="link" href="glib-Testing.html#g-test-init" title="g_test_init ()"><code class="function">g_test_init()</code></a>.
451 <a class="link" href="glib-Testing.html#g-test-run-suite" title="g_test_run_suite ()"><code class="function">g_test_run_suite()</code></a> or <a class="link" href="glib-Testing.html#g-test-run" title="g_test_run ()"><code class="function">g_test_run()</code></a> may only be called once
452 in a program.</p>
453 <div class="variablelist"><table border="0">
454 <col align="left" valign="top">
455 <tbody><tr>
456 <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
457 <td> 0 on success
458
459 </td>
460 </tr></tbody>
461 </table></div>
462 <p class="since">Since 2.16</p>
463 </div>
464 <hr>
465 <div class="refsect2" title="g_test_add_func ()">
466 <a name="g-test-add-func"></a><h3>g_test_add_func ()</h3>
467 <pre class="programlisting"><span class="returnvalue">void</span>                g_test_add_func                     (const <span class="returnvalue">char</span> *testpath,
468                                                          <span class="returnvalue">void</span> (test_funcvoid) ());</pre>
469 <p>
470 Create a new test case, similar to <a class="link" href="glib-Testing.html#g-test-create-case" title="g_test_create_case ()"><code class="function">g_test_create_case()</code></a>. However
471 the test is assumed to use no fixture, and test suites are automatically
472 created on the fly and added to the root fixture, based on the
473 slash-separated portions of <em class="parameter"><code>testpath</code></em>.</p>
474 <div class="variablelist"><table border="0">
475 <col align="left" valign="top">
476 <tbody>
477 <tr>
478 <td><p><span class="term"><em class="parameter"><code>testpath</code></em> :</span></p></td>
479 <td>   Slash-separated test case path name for the test.
480 </td>
481 </tr>
482 <tr>
483 <td><p><span class="term"><em class="parameter"><code>test_func</code></em> :</span></p></td>
484 <td>  The test function to invoke for this test.
485 </td>
486 </tr>
487 </tbody>
488 </table></div>
489 <p class="since">Since 2.16</p>
490 </div>
491 <hr>
492 <div class="refsect2" title="g_test_add_data_func ()">
493 <a name="g-test-add-data-func"></a><h3>g_test_add_data_func ()</h3>
494 <pre class="programlisting"><span class="returnvalue">void</span>                g_test_add_data_func                (const <span class="returnvalue">char</span> *testpath,
495                                                          <a class="link" href="glib-Basic-Types.html#gconstpointer" title="gconstpointer"><span class="returnvalue">gconstpointer</span></a> test_data,
496                                                          <span class="returnvalue">void</span> (test_funcgconstpointer) ());</pre>
497 <p>
498 Create a new test case, similar to <a class="link" href="glib-Testing.html#g-test-create-case" title="g_test_create_case ()"><code class="function">g_test_create_case()</code></a>. However
499 the test is assumed to use no fixture, and test suites are automatically
500 created on the fly and added to the root fixture, based on the
501 slash-separated portions of <em class="parameter"><code>testpath</code></em>. The <em class="parameter"><code>test_data</code></em> argument
502 will be passed as first argument to <em class="parameter"><code>test_func</code></em>.</p>
503 <div class="variablelist"><table border="0">
504 <col align="left" valign="top">
505 <tbody>
506 <tr>
507 <td><p><span class="term"><em class="parameter"><code>testpath</code></em> :</span></p></td>
508 <td>   Slash-separated test case path name for the test.
509 </td>
510 </tr>
511 <tr>
512 <td><p><span class="term"><em class="parameter"><code>test_data</code></em> :</span></p></td>
513 <td>  Test data argument for the test function.
514 </td>
515 </tr>
516 <tr>
517 <td><p><span class="term"><em class="parameter"><code>test_func</code></em> :</span></p></td>
518 <td>  The test function to invoke for this test.
519 </td>
520 </tr>
521 </tbody>
522 </table></div>
523 <p class="since">Since 2.16</p>
524 </div>
525 <hr>
526 <div class="refsect2" title="g_test_add()">
527 <a name="g-test-add"></a><h3>g_test_add()</h3>
528 <pre class="programlisting">#define             g_test_add(testpath, Fixture, tdata, fsetup, ftest, fteardown)</pre>
529 <p>
530 Hook up a new test case at <em class="parameter"><code>testpath</code></em>, similar to <a class="link" href="glib-Testing.html#g-test-add-func" title="g_test_add_func ()"><code class="function">g_test_add_func()</code></a>.
531 A fixture data structure with setup and teardown function may be provided
532 though, similar to <a class="link" href="glib-Testing.html#g-test-create-case" title="g_test_create_case ()"><code class="function">g_test_create_case()</code></a>.
533 <a class="link" href="glib-Testing.html#g-test-add" title="g_test_add()"><code class="function">g_test_add()</code></a> is implemented as a macro, so that the <code class="function">fsetup()</code>, <code class="function">ftest()</code> and
534 <code class="function">fteardown()</code> callbacks can expect a <em class="parameter"><code>Fixture</code></em> pointer as first argument in
535 a type safe manner.</p>
536 <div class="variablelist"><table border="0">
537 <col align="left" valign="top">
538 <tbody>
539 <tr>
540 <td><p><span class="term"><em class="parameter"><code>testpath</code></em> :</span></p></td>
541 <td>  The test path for a new test case.
542 </td>
543 </tr>
544 <tr>
545 <td><p><span class="term"><em class="parameter"><code>Fixture</code></em> :</span></p></td>
546 <td>   The type of a fixture data structure.
547 </td>
548 </tr>
549 <tr>
550 <td><p><span class="term"><em class="parameter"><code>tdata</code></em> :</span></p></td>
551 <td>     Data argument for the test functions.
552 </td>
553 </tr>
554 <tr>
555 <td><p><span class="term"><em class="parameter"><code>fsetup</code></em> :</span></p></td>
556 <td>    The function to set up the fixture data.
557 </td>
558 </tr>
559 <tr>
560 <td><p><span class="term"><em class="parameter"><code>ftest</code></em> :</span></p></td>
561 <td>     The actual test function.
562 </td>
563 </tr>
564 <tr>
565 <td><p><span class="term"><em class="parameter"><code>fteardown</code></em> :</span></p></td>
566 <td> The function to tear down the fixture data.
567 </td>
568 </tr>
569 </tbody>
570 </table></div>
571 <p class="since">Since 2.16</p>
572 </div>
573 <hr>
574 <div class="refsect2" title="g_test_message ()">
575 <a name="g-test-message"></a><h3>g_test_message ()</h3>
576 <pre class="programlisting"><span class="returnvalue">void</span>                g_test_message                      (const <span class="returnvalue">char</span> *format,
577                                                          ...);</pre>
578 <p>
579 Add a message to the test report.</p>
580 <div class="variablelist"><table border="0">
581 <col align="left" valign="top">
582 <tbody>
583 <tr>
584 <td><p><span class="term"><em class="parameter"><code>format</code></em> :</span></p></td>
585 <td> the format string
586 </td>
587 </tr>
588 <tr>
589 <td><p><span class="term"><em class="parameter"><code>...</code></em> :</span></p></td>
590 <td>    printf-like arguments to <em class="parameter"><code>format</code></em>
591 </td>
592 </tr>
593 </tbody>
594 </table></div>
595 <p class="since">Since 2.16</p>
596 </div>
597 <hr>
598 <div class="refsect2" title="g_test_bug_base ()">
599 <a name="g-test-bug-base"></a><h3>g_test_bug_base ()</h3>
600 <pre class="programlisting"><span class="returnvalue">void</span>                g_test_bug_base                     (const <span class="returnvalue">char</span> *uri_pattern);</pre>
601 <p>
602 Specify the base URI for bug reports.
603 </p>
604 <p>
605 The base URI is used to construct bug report messages for
606 <a class="link" href="glib-Testing.html#g-test-message" title="g_test_message ()"><code class="function">g_test_message()</code></a> when <a class="link" href="glib-Testing.html#g-test-bug" title="g_test_bug ()"><code class="function">g_test_bug()</code></a> is called.
607 Calling this function outside of a test case sets the
608 default base URI for all test cases. Calling it from within
609 a test case changes the base URI for the scope of the test
610 case only.
611 Bug URIs are constructed by appending a bug specific URI
612 portion to <em class="parameter"><code>uri_pattern</code></em>, or by replacing the special string
613 '<code class="literal">s</code>' within <em class="parameter"><code>uri_pattern</code></em> if that is present.</p>
614 <div class="variablelist"><table border="0">
615 <col align="left" valign="top">
616 <tbody><tr>
617 <td><p><span class="term"><em class="parameter"><code>uri_pattern</code></em> :</span></p></td>
618 <td> the base pattern for bug URIs
619 </td>
620 </tr></tbody>
621 </table></div>
622 <p class="since">Since 2.16</p>
623 </div>
624 <hr>
625 <div class="refsect2" title="g_test_bug ()">
626 <a name="g-test-bug"></a><h3>g_test_bug ()</h3>
627 <pre class="programlisting"><span class="returnvalue">void</span>                g_test_bug                          (const <span class="returnvalue">char</span> *bug_uri_snippet);</pre>
628 <p>
629 This function adds a message to test reports that
630 associates a bug URI with a test case.
631 Bug URIs are constructed from a base URI set with <a class="link" href="glib-Testing.html#g-test-bug-base" title="g_test_bug_base ()"><code class="function">g_test_bug_base()</code></a>
632 and <em class="parameter"><code>bug_uri_snippet</code></em>.</p>
633 <div class="variablelist"><table border="0">
634 <col align="left" valign="top">
635 <tbody><tr>
636 <td><p><span class="term"><em class="parameter"><code>bug_uri_snippet</code></em> :</span></p></td>
637 <td> Bug specific bug tracker URI portion.
638 </td>
639 </tr></tbody>
640 </table></div>
641 <p class="since">Since 2.16</p>
642 </div>
643 <hr>
644 <div class="refsect2" title="GTestLogFatalFunc ()">
645 <a name="GTestLogFatalFunc"></a><h3>GTestLogFatalFunc ()</h3>
646 <pre class="programlisting"><a class="link" href="glib-Basic-Types.html#gboolean" title="gboolean"><span class="returnvalue">gboolean</span></a>            (*GTestLogFatalFunc)                (const <a class="link" href="glib-Basic-Types.html#gchar" title="gchar"><span class="returnvalue">gchar</span></a> *log_domain,
647                                                          <a class="link" href="glib-Message-Logging.html#GLogLevelFlags" title="enum GLogLevelFlags"><span class="returnvalue">GLogLevelFlags</span></a> log_level,
648                                                          const <a class="link" href="glib-Basic-Types.html#gchar" title="gchar"><span class="returnvalue">gchar</span></a> *message,
649                                                          <a class="link" href="glib-Basic-Types.html#gpointer" title="gpointer"><span class="returnvalue">gpointer</span></a> user_data);</pre>
650 <p>
651 Specifies the prototype of fatal log handler functions.</p>
652 <div class="variablelist"><table border="0">
653 <col align="left" valign="top">
654 <tbody>
655 <tr>
656 <td><p><span class="term"><em class="parameter"><code>log_domain</code></em> :</span></p></td>
657 <td> the log domain of the message
658 </td>
659 </tr>
660 <tr>
661 <td><p><span class="term"><em class="parameter"><code>log_level</code></em> :</span></p></td>
662 <td> the log level of the message (including the fatal and recursion flags)
663 </td>
664 </tr>
665 <tr>
666 <td><p><span class="term"><em class="parameter"><code>message</code></em> :</span></p></td>
667 <td> the message to process
668 </td>
669 </tr>
670 <tr>
671 <td><p><span class="term"><em class="parameter"><code>user_data</code></em> :</span></p></td>
672 <td> user data, set in <a class="link" href="glib-Testing.html#g-test-log-set-fatal-handler" title="g_test_log_set_fatal_handler ()"><code class="function">g_test_log_set_fatal_handler()</code></a>
673 </td>
674 </tr>
675 <tr>
676 <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
677 <td> <a class="link" href="glib-Standard-Macros.html#TRUE:CAPS" title="TRUE"><code class="literal">TRUE</code></a> if the program should abort, <a class="link" href="glib-Standard-Macros.html#FALSE:CAPS" title="FALSE"><code class="literal">FALSE</code></a> otherwise
678
679 </td>
680 </tr>
681 </tbody>
682 </table></div>
683 <p class="since">Since 2.22</p>
684 </div>
685 <hr>
686 <div class="refsect2" title="g_test_log_set_fatal_handler ()">
687 <a name="g-test-log-set-fatal-handler"></a><h3>g_test_log_set_fatal_handler ()</h3>
688 <pre class="programlisting"><span class="returnvalue">void</span>                g_test_log_set_fatal_handler        (<a class="link" href="glib-Testing.html#GTestLogFatalFunc" title="GTestLogFatalFunc ()"><span class="returnvalue">GTestLogFatalFunc</span></a> log_func,
689                                                          <a class="link" href="glib-Basic-Types.html#gpointer" title="gpointer"><span class="returnvalue">gpointer</span></a> user_data);</pre>
690 <p>
691 Installs a non-error fatal log handler which can be
692 used to decide whether log messages which are counted
693 as fatal abort the program.
694 </p>
695 <p>
696 The use case here is that you are running a test case
697 that depends on particular libraries or circumstances
698 and cannot prevent certain known critical or warning
699 messages. So you install a handler that compares the
700 domain and message to precisely not abort in such a case.
701 </p>
702 <p>
703 Note that the handler is reset at the beginning of
704 any test case, so you have to set it inside each test
705 function which needs the special behavior.
706 </p>
707 <p>
708 This handler has no effect on g_error messages.</p>
709 <div class="variablelist"><table border="0">
710 <col align="left" valign="top">
711 <tbody>
712 <tr>
713 <td><p><span class="term"><em class="parameter"><code>log_func</code></em> :</span></p></td>
714 <td> the log handler function.
715 </td>
716 </tr>
717 <tr>
718 <td><p><span class="term"><em class="parameter"><code>user_data</code></em> :</span></p></td>
719 <td> data passed to the log handler.
720 </td>
721 </tr>
722 </tbody>
723 </table></div>
724 <p class="since">Since 2.22</p>
725 </div>
726 <hr>
727 <div class="refsect2" title="g_test_timer_start ()">
728 <a name="g-test-timer-start"></a><h3>g_test_timer_start ()</h3>
729 <pre class="programlisting"><span class="returnvalue">void</span>                g_test_timer_start                  (void);</pre>
730 <p>
731 Start a timing test. Call <a class="link" href="glib-Testing.html#g-test-timer-elapsed" title="g_test_timer_elapsed ()"><code class="function">g_test_timer_elapsed()</code></a> when the task is supposed
732 to be done. Call this function again to restart the timer.</p>
733 <p class="since">Since 2.16</p>
734 </div>
735 <hr>
736 <div class="refsect2" title="g_test_timer_elapsed ()">
737 <a name="g-test-timer-elapsed"></a><h3>g_test_timer_elapsed ()</h3>
738 <pre class="programlisting"><span class="returnvalue">double</span>              g_test_timer_elapsed                (void);</pre>
739 <p>
740 Get the time since the last start of the timer with <a class="link" href="glib-Testing.html#g-test-timer-start" title="g_test_timer_start ()"><code class="function">g_test_timer_start()</code></a>.</p>
741 <div class="variablelist"><table border="0">
742 <col align="left" valign="top">
743 <tbody><tr>
744 <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
745 <td> the time since the last start of the timer, as a double
746
747 </td>
748 </tr></tbody>
749 </table></div>
750 <p class="since">Since 2.16</p>
751 </div>
752 <hr>
753 <div class="refsect2" title="g_test_timer_last ()">
754 <a name="g-test-timer-last"></a><h3>g_test_timer_last ()</h3>
755 <pre class="programlisting"><span class="returnvalue">double</span>              g_test_timer_last                   (void);</pre>
756 <p>
757 Report the last result of <a class="link" href="glib-Testing.html#g-test-timer-elapsed" title="g_test_timer_elapsed ()"><code class="function">g_test_timer_elapsed()</code></a>.</p>
758 <div class="variablelist"><table border="0">
759 <col align="left" valign="top">
760 <tbody><tr>
761 <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
762 <td> the last result of <a class="link" href="glib-Testing.html#g-test-timer-elapsed" title="g_test_timer_elapsed ()"><code class="function">g_test_timer_elapsed()</code></a>, as a double
763
764 </td>
765 </tr></tbody>
766 </table></div>
767 <p class="since">Since 2.16</p>
768 </div>
769 <hr>
770 <div class="refsect2" title="g_test_queue_free ()">
771 <a name="g-test-queue-free"></a><h3>g_test_queue_free ()</h3>
772 <pre class="programlisting"><span class="returnvalue">void</span>                g_test_queue_free                   (<a class="link" href="glib-Basic-Types.html#gpointer" title="gpointer"><span class="returnvalue">gpointer</span></a> gfree_pointer);</pre>
773 <p>
774 Enqueue a pointer to be released with <a class="link" href="glib-Memory-Allocation.html#g-free" title="g_free ()"><code class="function">g_free()</code></a> during the next
775 teardown phase. This is equivalent to calling <a class="link" href="glib-Testing.html#g-test-queue-destroy" title="g_test_queue_destroy ()"><code class="function">g_test_queue_destroy()</code></a>
776 with a destroy callback of <a class="link" href="glib-Memory-Allocation.html#g-free" title="g_free ()"><code class="function">g_free()</code></a>.</p>
777 <div class="variablelist"><table border="0">
778 <col align="left" valign="top">
779 <tbody><tr>
780 <td><p><span class="term"><em class="parameter"><code>gfree_pointer</code></em> :</span></p></td>
781 <td> the pointer to be stored.
782 </td>
783 </tr></tbody>
784 </table></div>
785 <p class="since">Since 2.16</p>
786 </div>
787 <hr>
788 <div class="refsect2" title="g_test_queue_destroy ()">
789 <a name="g-test-queue-destroy"></a><h3>g_test_queue_destroy ()</h3>
790 <pre class="programlisting"><span class="returnvalue">void</span>                g_test_queue_destroy                (<a class="link" href="glib-Datasets.html#GDestroyNotify" title="GDestroyNotify ()"><span class="returnvalue">GDestroyNotify</span></a> destroy_func,
791                                                          <a class="link" href="glib-Basic-Types.html#gpointer" title="gpointer"><span class="returnvalue">gpointer</span></a> destroy_data);</pre>
792 <p>
793 This function enqueus a callback @<code class="function">destroy_func()</code> to be executed
794 during the next test case teardown phase. This is most useful
795 to auto destruct allocted test resources at the end of a test run.
796 Resources are released in reverse queue order, that means enqueueing
797 callback A before callback B will cause <code class="function">B()</code> to be called before
798 <code class="function">A()</code> during teardown.</p>
799 <div class="variablelist"><table border="0">
800 <col align="left" valign="top">
801 <tbody>
802 <tr>
803 <td><p><span class="term"><em class="parameter"><code>destroy_func</code></em> :</span></p></td>
804 <td>       Destroy callback for teardown phase.
805 </td>
806 </tr>
807 <tr>
808 <td><p><span class="term"><em class="parameter"><code>destroy_data</code></em> :</span></p></td>
809 <td>       Destroy callback data.
810 </td>
811 </tr>
812 </tbody>
813 </table></div>
814 <p class="since">Since 2.16</p>
815 </div>
816 <hr>
817 <div class="refsect2" title="g_test_queue_unref()">
818 <a name="g-test-queue-unref"></a><h3>g_test_queue_unref()</h3>
819 <pre class="programlisting">#define             g_test_queue_unref(gobject)</pre>
820 <p>
821 Enqueue an object to be released with <a href="http://library.gnome.org/devel/gobject/unstable/gobject-The-Base-Object-Type.html#g-object-unref"><code class="function">g_object_unref()</code></a> during
822 the next teardown phase. This is equivalent to calling <a class="link" href="glib-Testing.html#g-test-queue-destroy" title="g_test_queue_destroy ()"><code class="function">g_test_queue_destroy()</code></a>
823 with a destroy callback of <a href="http://library.gnome.org/devel/gobject/unstable/gobject-The-Base-Object-Type.html#g-object-unref"><code class="function">g_object_unref()</code></a>.
824 </p>
825 <div class="variablelist"><table border="0">
826 <col align="left" valign="top">
827 <tbody><tr>
828 <td><p><span class="term"><em class="parameter"><code>gobject</code></em> :</span></p></td>
829 <td>the object to unref
830 </td>
831 </tr></tbody>
832 </table></div>
833 <p class="since">Since 2.16</p>
834 </div>
835 <hr>
836 <div class="refsect2" title="enum GTestTrapFlags">
837 <a name="GTestTrapFlags"></a><h3>enum GTestTrapFlags</h3>
838 <pre class="programlisting">typedef enum {
839   G_TEST_TRAP_SILENCE_STDOUT    = 1 &lt;&lt; 7,
840   G_TEST_TRAP_SILENCE_STDERR    = 1 &lt;&lt; 8,
841   G_TEST_TRAP_INHERIT_STDIN     = 1 &lt;&lt; 9
842 } GTestTrapFlags;
843 </pre>
844 <p>
845 Test traps are guards around forked tests. These flags
846 determine what traps to set.
847 </p>
848 <div class="variablelist"><table border="0">
849 <col align="left" valign="top">
850 <tbody>
851 <tr>
852 <td><p><a name="G-TEST-TRAP-SILENCE-STDOUT:CAPS"></a><span class="term"><code class="literal">G_TEST_TRAP_SILENCE_STDOUT</code></span></p></td>
853 <td>Redirect stdout of the test child to 
854     <code class="filename">/dev/null</code> so it cannot be observed on the
855     console during test runs. The actual output is still captured
856     though to allow later tests with <a class="link" href="glib-Testing.html#g-test-trap-assert-stdout" title="g_test_trap_assert_stdout()"><code class="function">g_test_trap_assert_stdout()</code></a>.
857 </td>
858 </tr>
859 <tr>
860 <td><p><a name="G-TEST-TRAP-SILENCE-STDERR:CAPS"></a><span class="term"><code class="literal">G_TEST_TRAP_SILENCE_STDERR</code></span></p></td>
861 <td>Redirect stderr of the test child to 
862     <code class="filename">/dev/null</code> so it cannot be observed on the
863     console during test runs. The actual output is still captured
864     though to allow later tests with <a class="link" href="glib-Testing.html#g-test-trap-assert-stderr" title="g_test_trap_assert_stderr()"><code class="function">g_test_trap_assert_stderr()</code></a>.
865 </td>
866 </tr>
867 <tr>
868 <td><p><a name="G-TEST-TRAP-INHERIT-STDIN:CAPS"></a><span class="term"><code class="literal">G_TEST_TRAP_INHERIT_STDIN</code></span></p></td>
869 <td>If this flag is given, stdin of the forked 
870     child process is shared with stdin of its parent process. It is
871     redirected to <code class="filename">/dev/null</code> otherwise.
872 </td>
873 </tr>
874 </tbody>
875 </table></div>
876 </div>
877 <hr>
878 <div class="refsect2" title="g_test_trap_fork ()">
879 <a name="g-test-trap-fork"></a><h3>g_test_trap_fork ()</h3>
880 <pre class="programlisting"><a class="link" href="glib-Basic-Types.html#gboolean" title="gboolean"><span class="returnvalue">gboolean</span></a>            g_test_trap_fork                    (<a class="link" href="glib-Basic-Types.html#guint64" title="guint64"><span class="returnvalue">guint64</span></a> usec_timeout,
881                                                          <a class="link" href="glib-Testing.html#GTestTrapFlags" title="enum GTestTrapFlags"><span class="returnvalue">GTestTrapFlags</span></a> test_trap_flags);</pre>
882 <p>
883 Fork the current test program to execute a test case that might
884 not return or that might abort. The forked test case is aborted
885 and considered failing if its run time exceeds <em class="parameter"><code>usec_timeout</code></em>.
886 </p>
887 <p>
888 The forking behavior can be configured with the <a class="link" href="glib-Testing.html#GTestTrapFlags" title="enum GTestTrapFlags"><span class="type">GTestTrapFlags</span></a> flags.
889 </p>
890 <p>
891 In the following example, the test code forks, the forked child
892 process produces some sample output and exits successfully.
893 The forking parent process then asserts successful child program
894 termination and validates child program outputs.
895 </p>
896 <p>
897 </p>
898 <div class="informalexample"><pre class="programlisting">
899   static void
900   test_fork_patterns (void)
901   {
902     if (g_test_trap_fork (0, G_TEST_TRAP_SILENCE_STDOUT | G_TEST_TRAP_SILENCE_STDERR))
903       {
904         g_print ("some stdout text: somagic17\n");
905         g_printerr ("some stderr text: semagic43\n");
906         exit (0); /* successful test run */
907       }
908     g_test_trap_assert_passed();
909     g_test_trap_assert_stdout ("*somagic17*");
910     g_test_trap_assert_stderr ("*semagic43*");
911   }
912 </pre></div>
913 <p>
914 </p>
915 <p>
916 This function is implemented only on Unix platforms.</p>
917 <div class="variablelist"><table border="0">
918 <col align="left" valign="top">
919 <tbody>
920 <tr>
921 <td><p><span class="term"><em class="parameter"><code>usec_timeout</code></em> :</span></p></td>
922 <td>    Timeout for the forked test in micro seconds.
923 </td>
924 </tr>
925 <tr>
926 <td><p><span class="term"><em class="parameter"><code>test_trap_flags</code></em> :</span></p></td>
927 <td> Flags to modify forking behaviour.
928 </td>
929 </tr>
930 <tr>
931 <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
932 <td> <a class="link" href="glib-Standard-Macros.html#TRUE:CAPS" title="TRUE"><code class="literal">TRUE</code></a> for the forked child and <a class="link" href="glib-Standard-Macros.html#FALSE:CAPS" title="FALSE"><code class="literal">FALSE</code></a> for the executing parent process.
933
934 </td>
935 </tr>
936 </tbody>
937 </table></div>
938 <p class="since">Since 2.16</p>
939 </div>
940 <hr>
941 <div class="refsect2" title="g_test_trap_has_passed ()">
942 <a name="g-test-trap-has-passed"></a><h3>g_test_trap_has_passed ()</h3>
943 <pre class="programlisting"><a class="link" href="glib-Basic-Types.html#gboolean" title="gboolean"><span class="returnvalue">gboolean</span></a>            g_test_trap_has_passed              (void);</pre>
944 <p>
945 Check the result of the last <a class="link" href="glib-Testing.html#g-test-trap-fork" title="g_test_trap_fork ()"><code class="function">g_test_trap_fork()</code></a> call.</p>
946 <div class="variablelist"><table border="0">
947 <col align="left" valign="top">
948 <tbody><tr>
949 <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
950 <td> <a class="link" href="glib-Standard-Macros.html#TRUE:CAPS" title="TRUE"><code class="literal">TRUE</code></a> if the last forked child terminated successfully.
951
952 </td>
953 </tr></tbody>
954 </table></div>
955 <p class="since">Since 2.16</p>
956 </div>
957 <hr>
958 <div class="refsect2" title="g_test_trap_reached_timeout ()">
959 <a name="g-test-trap-reached-timeout"></a><h3>g_test_trap_reached_timeout ()</h3>
960 <pre class="programlisting"><a class="link" href="glib-Basic-Types.html#gboolean" title="gboolean"><span class="returnvalue">gboolean</span></a>            g_test_trap_reached_timeout         (void);</pre>
961 <p>
962 Check the result of the last <a class="link" href="glib-Testing.html#g-test-trap-fork" title="g_test_trap_fork ()"><code class="function">g_test_trap_fork()</code></a> call.</p>
963 <div class="variablelist"><table border="0">
964 <col align="left" valign="top">
965 <tbody><tr>
966 <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
967 <td> <a class="link" href="glib-Standard-Macros.html#TRUE:CAPS" title="TRUE"><code class="literal">TRUE</code></a> if the last forked child got killed due to a fork timeout.
968
969 </td>
970 </tr></tbody>
971 </table></div>
972 <p class="since">Since 2.16</p>
973 </div>
974 <hr>
975 <div class="refsect2" title="g_test_trap_assert_passed()">
976 <a name="g-test-trap-assert-passed"></a><h3>g_test_trap_assert_passed()</h3>
977 <pre class="programlisting">#define             g_test_trap_assert_passed()</pre>
978 <p>
979 Assert that the last forked test passed. See <a class="link" href="glib-Testing.html#g-test-trap-fork" title="g_test_trap_fork ()"><code class="function">g_test_trap_fork()</code></a>.
980 </p>
981 <p class="since">Since 2.16</p>
982 </div>
983 <hr>
984 <div class="refsect2" title="g_test_trap_assert_failed()">
985 <a name="g-test-trap-assert-failed"></a><h3>g_test_trap_assert_failed()</h3>
986 <pre class="programlisting">#define             g_test_trap_assert_failed()</pre>
987 <p>
988 Assert that the last forked test failed. See <a class="link" href="glib-Testing.html#g-test-trap-fork" title="g_test_trap_fork ()"><code class="function">g_test_trap_fork()</code></a>.
989 </p>
990 <p class="since">Since 2.16</p>
991 </div>
992 <hr>
993 <div class="refsect2" title="g_test_trap_assert_stdout()">
994 <a name="g-test-trap-assert-stdout"></a><h3>g_test_trap_assert_stdout()</h3>
995 <pre class="programlisting">#define             g_test_trap_assert_stdout(soutpattern)</pre>
996 <p>
997 Assert that the stdout output of the last forked test matches <em class="parameter"><code>soutpattern</code></em>.
998 See <a class="link" href="glib-Testing.html#g-test-trap-fork" title="g_test_trap_fork ()"><code class="function">g_test_trap_fork()</code></a>.
999 </p>
1000 <div class="variablelist"><table border="0">
1001 <col align="left" valign="top">
1002 <tbody><tr>
1003 <td><p><span class="term"><em class="parameter"><code>soutpattern</code></em> :</span></p></td>
1004 <td>a glob-style <a class="link" href="glib-Glob-style-pattern-matching.html" title="Glob-style pattern matching">pattern</a>
1005 </td>
1006 </tr></tbody>
1007 </table></div>
1008 <p class="since">Since 2.16</p>
1009 </div>
1010 <hr>
1011 <div class="refsect2" title="g_test_trap_assert_stdout_unmatched()">
1012 <a name="g-test-trap-assert-stdout-unmatched"></a><h3>g_test_trap_assert_stdout_unmatched()</h3>
1013 <pre class="programlisting">#define             g_test_trap_assert_stdout_unmatched(soutpattern)</pre>
1014 <p>
1015 Assert that the stdout output of the last forked test does not match
1016 <em class="parameter"><code>soutpattern</code></em>.  See <a class="link" href="glib-Testing.html#g-test-trap-fork" title="g_test_trap_fork ()"><code class="function">g_test_trap_fork()</code></a>.
1017 </p>
1018 <div class="variablelist"><table border="0">
1019 <col align="left" valign="top">
1020 <tbody><tr>
1021 <td><p><span class="term"><em class="parameter"><code>soutpattern</code></em> :</span></p></td>
1022 <td>a glob-style <a class="link" href="glib-Glob-style-pattern-matching.html" title="Glob-style pattern matching">pattern</a>
1023 </td>
1024 </tr></tbody>
1025 </table></div>
1026 <p class="since">Since 2.16</p>
1027 </div>
1028 <hr>
1029 <div class="refsect2" title="g_test_trap_assert_stderr()">
1030 <a name="g-test-trap-assert-stderr"></a><h3>g_test_trap_assert_stderr()</h3>
1031 <pre class="programlisting">#define             g_test_trap_assert_stderr(serrpattern)</pre>
1032 <p>
1033 Assert that the stderr output of the last forked test matches <em class="parameter"><code>serrpattern</code></em>.
1034 See <a class="link" href="glib-Testing.html#g-test-trap-fork" title="g_test_trap_fork ()"><code class="function">g_test_trap_fork()</code></a>.
1035 </p>
1036 <div class="variablelist"><table border="0">
1037 <col align="left" valign="top">
1038 <tbody><tr>
1039 <td><p><span class="term"><em class="parameter"><code>serrpattern</code></em> :</span></p></td>
1040 <td>a glob-style <a class="link" href="glib-Glob-style-pattern-matching.html" title="Glob-style pattern matching">pattern</a>
1041 </td>
1042 </tr></tbody>
1043 </table></div>
1044 <p class="since">Since 2.16</p>
1045 </div>
1046 <hr>
1047 <div class="refsect2" title="g_test_trap_assert_stderr_unmatched()">
1048 <a name="g-test-trap-assert-stderr-unmatched"></a><h3>g_test_trap_assert_stderr_unmatched()</h3>
1049 <pre class="programlisting">#define             g_test_trap_assert_stderr_unmatched(serrpattern)</pre>
1050 <p>
1051 Assert that the stderr output of the last forked test does not match
1052 <em class="parameter"><code>serrpattern</code></em>.  See <a class="link" href="glib-Testing.html#g-test-trap-fork" title="g_test_trap_fork ()"><code class="function">g_test_trap_fork()</code></a>.
1053 </p>
1054 <div class="variablelist"><table border="0">
1055 <col align="left" valign="top">
1056 <tbody><tr>
1057 <td><p><span class="term"><em class="parameter"><code>serrpattern</code></em> :</span></p></td>
1058 <td>a glob-style <a class="link" href="glib-Glob-style-pattern-matching.html" title="Glob-style pattern matching">pattern</a>
1059 </td>
1060 </tr></tbody>
1061 </table></div>
1062 <p class="since">Since 2.16</p>
1063 </div>
1064 <hr>
1065 <div class="refsect2" title="g_test_rand_bit()">
1066 <a name="g-test-rand-bit"></a><h3>g_test_rand_bit()</h3>
1067 <pre class="programlisting">#define             g_test_rand_bit()</pre>
1068 <p>
1069 Get a reproducible random bit (0 or 1),
1070 see <a class="link" href="glib-Testing.html#g-test-rand-int" title="g_test_rand_int ()"><code class="function">g_test_rand_int()</code></a> for details on test case random numbers.
1071 </p>
1072 <p class="since">Since 2.16</p>
1073 </div>
1074 <hr>
1075 <div class="refsect2" title="g_test_rand_int ()">
1076 <a name="g-test-rand-int"></a><h3>g_test_rand_int ()</h3>
1077 <pre class="programlisting"><a class="link" href="glib-Basic-Types.html#gint32" title="gint32"><span class="returnvalue">gint32</span></a>              g_test_rand_int                     (void);</pre>
1078 <p>
1079 Get a reproducible random integer number.
1080 </p>
1081 <p>
1082 The random numbers generated by the g_test_rand_*() family of functions
1083 change with every new test program start, unless the --seed option is
1084 given when starting test programs.
1085 </p>
1086 <p>
1087 For individual test cases however, the random number generator is
1088 reseeded, to avoid dependencies between tests and to make --seed
1089 effective for all test cases.</p>
1090 <div class="variablelist"><table border="0">
1091 <col align="left" valign="top">
1092 <tbody><tr>
1093 <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
1094 <td> a random number from the seeded random number generator.
1095
1096 </td>
1097 </tr></tbody>
1098 </table></div>
1099 <p class="since">Since 2.16</p>
1100 </div>
1101 <hr>
1102 <div class="refsect2" title="g_test_rand_int_range ()">
1103 <a name="g-test-rand-int-range"></a><h3>g_test_rand_int_range ()</h3>
1104 <pre class="programlisting"><a class="link" href="glib-Basic-Types.html#gint32" title="gint32"><span class="returnvalue">gint32</span></a>              g_test_rand_int_range               (<a class="link" href="glib-Basic-Types.html#gint32" title="gint32"><span class="returnvalue">gint32</span></a> begin,
1105                                                          <a class="link" href="glib-Basic-Types.html#gint32" title="gint32"><span class="returnvalue">gint32</span></a> end);</pre>
1106 <p>
1107 Get a reproducible random integer number out of a specified range,
1108 see <a class="link" href="glib-Testing.html#g-test-rand-int" title="g_test_rand_int ()"><code class="function">g_test_rand_int()</code></a> for details on test case random numbers.</p>
1109 <div class="variablelist"><table border="0">
1110 <col align="left" valign="top">
1111 <tbody>
1112 <tr>
1113 <td><p><span class="term"><em class="parameter"><code>begin</code></em> :</span></p></td>
1114 <td> the minimum value returned by this function
1115 </td>
1116 </tr>
1117 <tr>
1118 <td><p><span class="term"><em class="parameter"><code>end</code></em> :</span></p></td>
1119 <td>   the smallest value not to be returned by this function
1120 </td>
1121 </tr>
1122 <tr>
1123 <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
1124 <td> a number with <em class="parameter"><code>begin</code></em> &lt;= number &lt; <em class="parameter"><code>end</code></em>.
1125
1126 </td>
1127 </tr>
1128 </tbody>
1129 </table></div>
1130 <p class="since">Since 2.16</p>
1131 </div>
1132 <hr>
1133 <div class="refsect2" title="g_test_rand_double ()">
1134 <a name="g-test-rand-double"></a><h3>g_test_rand_double ()</h3>
1135 <pre class="programlisting"><span class="returnvalue">double</span>              g_test_rand_double                  (void);</pre>
1136 <p>
1137 Get a reproducible random floating point number,
1138 see <a class="link" href="glib-Testing.html#g-test-rand-int" title="g_test_rand_int ()"><code class="function">g_test_rand_int()</code></a> for details on test case random numbers.</p>
1139 <div class="variablelist"><table border="0">
1140 <col align="left" valign="top">
1141 <tbody><tr>
1142 <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
1143 <td> a random number from the seeded random number generator.
1144
1145 </td>
1146 </tr></tbody>
1147 </table></div>
1148 <p class="since">Since 2.16</p>
1149 </div>
1150 <hr>
1151 <div class="refsect2" title="g_test_rand_double_range ()">
1152 <a name="g-test-rand-double-range"></a><h3>g_test_rand_double_range ()</h3>
1153 <pre class="programlisting"><span class="returnvalue">double</span>              g_test_rand_double_range            (<span class="returnvalue">double</span> range_start,
1154                                                          <span class="returnvalue">double</span> range_end);</pre>
1155 <p>
1156 Get a reproducible random floating pointer number out of a specified range,
1157 see <a class="link" href="glib-Testing.html#g-test-rand-int" title="g_test_rand_int ()"><code class="function">g_test_rand_int()</code></a> for details on test case random numbers.</p>
1158 <div class="variablelist"><table border="0">
1159 <col align="left" valign="top">
1160 <tbody>
1161 <tr>
1162 <td><p><span class="term"><em class="parameter"><code>range_start</code></em> :</span></p></td>
1163 <td> the minimum value returned by this function
1164 </td>
1165 </tr>
1166 <tr>
1167 <td><p><span class="term"><em class="parameter"><code>range_end</code></em> :</span></p></td>
1168 <td> the minimum value not returned by this function
1169 </td>
1170 </tr>
1171 <tr>
1172 <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
1173 <td> a number with <em class="parameter"><code>range_start</code></em> &lt;= number &lt; <em class="parameter"><code>range_end</code></em>.
1174
1175 </td>
1176 </tr>
1177 </tbody>
1178 </table></div>
1179 <p class="since">Since 2.16</p>
1180 </div>
1181 <hr>
1182 <div class="refsect2" title="g_assert()">
1183 <a name="g-assert"></a><h3>g_assert()</h3>
1184 <pre class="programlisting">#define             g_assert(expr)</pre>
1185 <p>
1186 Debugging macro to terminate the application if the assertion fails.
1187 If the assertion fails (i.e. the expression is not true), an error message
1188 is logged and the application is terminated.
1189 </p>
1190 <p>
1191 The macro can be turned off in final releases of code by defining
1192 <span class="type">G_DISABLE_ASSERT</span> when compiling the application.
1193 </p>
1194 <div class="variablelist"><table border="0">
1195 <col align="left" valign="top">
1196 <tbody><tr>
1197 <td><p><span class="term"><em class="parameter"><code>expr</code></em> :</span></p></td>
1198 <td>the expression to check.
1199 </td>
1200 </tr></tbody>
1201 </table></div>
1202 </div>
1203 <hr>
1204 <div class="refsect2" title="g_assert_not_reached()">
1205 <a name="g-assert-not-reached"></a><h3>g_assert_not_reached()</h3>
1206 <pre class="programlisting">#define             g_assert_not_reached()</pre>
1207 <p>
1208 Debugging macro to terminate the application if it is ever reached.
1209 If it is reached, an error message is logged and the application is terminated.
1210 </p>
1211 <p>
1212 The macro can be turned off in final releases of code by defining
1213 <span class="type">G_DISABLE_ASSERT</span> when compiling the application.
1214 </p>
1215 </div>
1216 <hr>
1217 <div class="refsect2" title="g_assert_cmpstr()">
1218 <a name="g-assert-cmpstr"></a><h3>g_assert_cmpstr()</h3>
1219 <pre class="programlisting">#define             g_assert_cmpstr(s1, cmp, s2)</pre>
1220 <p>
1221 Debugging macro to terminate the application with a warning message
1222 if a string comparison fails.
1223 The strings are compared using <a class="link" href="glib-String-Utility-Functions.html#g-strcmp0" title="g_strcmp0 ()"><code class="function">g_strcmp0()</code></a>.
1224 </p>
1225 <p>
1226 The effect of <code class="literal">g_assert_cmpstr (s1, op, s2)</code> is the same
1227 as <code class="literal">g_assert (g_strcmp0 (s1, s2) op 0)</code>. The advantage of this macro
1228 is that it can produce a message that includes the actual values of <em class="parameter"><code>s1</code></em>
1229 and <em class="parameter"><code>s2</code></em>.
1230 </p>
1231 <div class="informalexample"><pre class="programlisting">
1232   g_assert_cmpstr (mystring, ==, "fubar");
1233 </pre></div>
1234 <div class="variablelist"><table border="0">
1235 <col align="left" valign="top">
1236 <tbody>
1237 <tr>
1238 <td><p><span class="term"><em class="parameter"><code>s1</code></em> :</span></p></td>
1239 <td>a string (may be <a class="link" href="glib-Standard-Macros.html#NULL:CAPS" title="NULL"><code class="literal">NULL</code></a>)
1240 </td>
1241 </tr>
1242 <tr>
1243 <td><p><span class="term"><em class="parameter"><code>cmp</code></em> :</span></p></td>
1244 <td>The comparison operator to use. One of ==, !=, &lt;, &gt;, &lt;=, &gt;=.
1245 </td>
1246 </tr>
1247 <tr>
1248 <td><p><span class="term"><em class="parameter"><code>s2</code></em> :</span></p></td>
1249 <td>another string (may be <a class="link" href="glib-Standard-Macros.html#NULL:CAPS" title="NULL"><code class="literal">NULL</code></a>)
1250 </td>
1251 </tr>
1252 </tbody>
1253 </table></div>
1254 <p class="since">Since 2.16</p>
1255 </div>
1256 <hr>
1257 <div class="refsect2" title="g_assert_cmpint()">
1258 <a name="g-assert-cmpint"></a><h3>g_assert_cmpint()</h3>
1259 <pre class="programlisting">#define             g_assert_cmpint(n1, cmp, n2)</pre>
1260 <p>
1261 Debugging macro to terminate the application with a warning message
1262 if an integer comparison fails.
1263 </p>
1264 <p>
1265 The effect of <code class="literal">g_assert_cmpint (n1, op, n2)</code> is the same
1266 as <code class="literal">g_assert (n1 op n2)</code>. The advantage of this macro
1267 is that it can produce a message that includes the actual values of <em class="parameter"><code>n1</code></em>
1268 and <em class="parameter"><code>n2</code></em>.
1269 </p>
1270 <div class="variablelist"><table border="0">
1271 <col align="left" valign="top">
1272 <tbody>
1273 <tr>
1274 <td><p><span class="term"><em class="parameter"><code>n1</code></em> :</span></p></td>
1275 <td>an integer
1276 </td>
1277 </tr>
1278 <tr>
1279 <td><p><span class="term"><em class="parameter"><code>cmp</code></em> :</span></p></td>
1280 <td>The comparison operator to use. One of ==, !=, &lt;, &gt;, &lt;=, &gt;=.
1281 </td>
1282 </tr>
1283 <tr>
1284 <td><p><span class="term"><em class="parameter"><code>n2</code></em> :</span></p></td>
1285 <td>another integer
1286 </td>
1287 </tr>
1288 </tbody>
1289 </table></div>
1290 <p class="since">Since 2.16</p>
1291 </div>
1292 <hr>
1293 <div class="refsect2" title="g_assert_cmpuint()">
1294 <a name="g-assert-cmpuint"></a><h3>g_assert_cmpuint()</h3>
1295 <pre class="programlisting">#define             g_assert_cmpuint(n1, cmp, n2)</pre>
1296 <p>
1297 Debugging macro to terminate the application with a warning message
1298 if an unsigned integer comparison fails.
1299 </p>
1300 <p>
1301 The effect of <code class="literal">g_assert_cmpuint (n1, op, n2)</code> is the same
1302 as <code class="literal">g_assert (n1 op n2)</code>. The advantage of this macro
1303 is that it can produce a message that includes the actual values of <em class="parameter"><code>n1</code></em>
1304 and <em class="parameter"><code>n2</code></em>.
1305 </p>
1306 <div class="variablelist"><table border="0">
1307 <col align="left" valign="top">
1308 <tbody>
1309 <tr>
1310 <td><p><span class="term"><em class="parameter"><code>n1</code></em> :</span></p></td>
1311 <td>an unsigned integer
1312 </td>
1313 </tr>
1314 <tr>
1315 <td><p><span class="term"><em class="parameter"><code>cmp</code></em> :</span></p></td>
1316 <td>The comparison operator to use. One of ==, !=, &lt;, &gt;, &lt;=, &gt;=.
1317 </td>
1318 </tr>
1319 <tr>
1320 <td><p><span class="term"><em class="parameter"><code>n2</code></em> :</span></p></td>
1321 <td>another unsigned integer
1322 </td>
1323 </tr>
1324 </tbody>
1325 </table></div>
1326 <p class="since">Since 2.16</p>
1327 </div>
1328 <hr>
1329 <div class="refsect2" title="g_assert_cmphex()">
1330 <a name="g-assert-cmphex"></a><h3>g_assert_cmphex()</h3>
1331 <pre class="programlisting">#define             g_assert_cmphex(n1, cmp, n2)</pre>
1332 <p>
1333 Debugging macro to terminate the application with a warning message
1334 if an unsigned integer comparison fails. This is a variant of
1335 <a class="link" href="glib-Testing.html#g-assert-cmpuint" title="g_assert_cmpuint()"><code class="function">g_assert_cmpuint()</code></a> that displays the numbers in hexadecimal notation
1336 in the message.
1337 </p>
1338 <div class="variablelist"><table border="0">
1339 <col align="left" valign="top">
1340 <tbody>
1341 <tr>
1342 <td><p><span class="term"><em class="parameter"><code>n1</code></em> :</span></p></td>
1343 <td>an unsigned integer
1344 </td>
1345 </tr>
1346 <tr>
1347 <td><p><span class="term"><em class="parameter"><code>cmp</code></em> :</span></p></td>
1348 <td>The comparison operator to use. One of ==, !=, &lt;, &gt;, &lt;=, &gt;=.
1349 </td>
1350 </tr>
1351 <tr>
1352 <td><p><span class="term"><em class="parameter"><code>n2</code></em> :</span></p></td>
1353 <td>another unsigned integer
1354 </td>
1355 </tr>
1356 </tbody>
1357 </table></div>
1358 <p class="since">Since 2.16</p>
1359 </div>
1360 <hr>
1361 <div class="refsect2" title="g_assert_cmpfloat()">
1362 <a name="g-assert-cmpfloat"></a><h3>g_assert_cmpfloat()</h3>
1363 <pre class="programlisting">#define             g_assert_cmpfloat(n1,cmp,n2)</pre>
1364 <p>
1365 Debugging macro to terminate the application with a warning message
1366 if a floating point number comparison fails.
1367 </p>
1368 <p>
1369 The effect of <code class="literal">g_assert_cmpfloat (n1, op, n2)</code> is the same
1370 as <code class="literal">g_assert (n1 op n2)</code>. The advantage of this function
1371 is that it can produce a message that includes the actual values of <em class="parameter"><code>n1</code></em>
1372 and <em class="parameter"><code>n2</code></em>.
1373 </p>
1374 <div class="variablelist"><table border="0">
1375 <col align="left" valign="top">
1376 <tbody>
1377 <tr>
1378 <td><p><span class="term"><em class="parameter"><code>n1</code></em> :</span></p></td>
1379 <td>an floating point number
1380 </td>
1381 </tr>
1382 <tr>
1383 <td><p><span class="term"><em class="parameter"><code>cmp</code></em> :</span></p></td>
1384 <td>The comparison operator to use. One of ==, !=, &lt;, &gt;, &lt;=, &gt;=.
1385 </td>
1386 </tr>
1387 <tr>
1388 <td><p><span class="term"><em class="parameter"><code>n2</code></em> :</span></p></td>
1389 <td>another floating point number
1390 </td>
1391 </tr>
1392 </tbody>
1393 </table></div>
1394 <p class="since">Since 2.16</p>
1395 </div>
1396 <hr>
1397 <div class="refsect2" title="g_assert_no_error()">
1398 <a name="g-assert-no-error"></a><h3>g_assert_no_error()</h3>
1399 <pre class="programlisting">#define             g_assert_no_error(err)</pre>
1400 <p>
1401 Debugging macro to terminate the application with a warning message
1402 if a method has returned a <a class="link" href="glib-Error-Reporting.html#GError" title="GError"><span class="type">GError</span></a>.
1403 </p>
1404 <p>
1405 The effect of <code class="literal">g_assert_no_error (err)</code> is the same
1406 as <code class="literal">g_assert (err == NULL)</code>. The advantage of this macro
1407 is that it can produce a message that includes the error message and code.
1408 </p>
1409 <div class="variablelist"><table border="0">
1410 <col align="left" valign="top">
1411 <tbody><tr>
1412 <td><p><span class="term"><em class="parameter"><code>err</code></em> :</span></p></td>
1413 <td>a <a class="link" href="glib-Error-Reporting.html#GError" title="GError"><span class="type">GError</span></a>, possibly <a class="link" href="glib-Standard-Macros.html#NULL:CAPS" title="NULL"><code class="literal">NULL</code></a>
1414 </td>
1415 </tr></tbody>
1416 </table></div>
1417 <p class="since">Since 2.20</p>
1418 </div>
1419 <hr>
1420 <div class="refsect2" title="g_assert_error()">
1421 <a name="g-assert-error"></a><h3>g_assert_error()</h3>
1422 <pre class="programlisting">#define             g_assert_error(err, dom, c)</pre>
1423 <p>
1424 Debugging macro to terminate the application with a warning message
1425 if a method has not returned the correct <a class="link" href="glib-Error-Reporting.html#GError" title="GError"><span class="type">GError</span></a>.
1426 </p>
1427 <p>
1428 The effect of <code class="literal">g_assert_error (err, dom, c)</code> is the same
1429 as <code class="literal">g_assert (err != NULL &amp;&amp; err-&gt;domain == dom &amp;&amp; err-&gt;code == c)</code>.
1430 The advantage of this macro is that it can produce a message that
1431 includes the incorrect error message and code.
1432 </p>
1433 <p>
1434 This can only be used to test for a specific error. If you want to
1435 test that <em class="parameter"><code>err</code></em> is set, but don't care what it's set to, just use
1436 <code class="literal">g_assert (err != NULL)</code>
1437 </p>
1438 <div class="variablelist"><table border="0">
1439 <col align="left" valign="top">
1440 <tbody>
1441 <tr>
1442 <td><p><span class="term"><em class="parameter"><code>err</code></em> :</span></p></td>
1443 <td>a <a class="link" href="glib-Error-Reporting.html#GError" title="GError"><span class="type">GError</span></a>, possibly <a class="link" href="glib-Standard-Macros.html#NULL:CAPS" title="NULL"><code class="literal">NULL</code></a>
1444 </td>
1445 </tr>
1446 <tr>
1447 <td><p><span class="term"><em class="parameter"><code>dom</code></em> :</span></p></td>
1448 <td>the expected error domain (a <a class="link" href="glib-Quarks.html#GQuark" title="GQuark"><span class="type">GQuark</span></a>)
1449 </td>
1450 </tr>
1451 <tr>
1452 <td><p><span class="term"><em class="parameter"><code>c</code></em> :</span></p></td>
1453 <td>the expected error code
1454 </td>
1455 </tr>
1456 </tbody>
1457 </table></div>
1458 <p class="since">Since 2.20</p>
1459 </div>
1460 <hr>
1461 <div class="refsect2" title="GTestCase">
1462 <a name="GTestCase"></a><h3>GTestCase</h3>
1463 <pre class="programlisting">typedef struct GTestCase  GTestCase;
1464 </pre>
1465 <p>
1466 An opaque structure representing a test case.
1467 </p>
1468 </div>
1469 <hr>
1470 <div class="refsect2" title="GTestSuite">
1471 <a name="GTestSuite"></a><h3>GTestSuite</h3>
1472 <pre class="programlisting">typedef struct GTestSuite GTestSuite;
1473 </pre>
1474 <p>
1475 An opaque structure representing a test suite.
1476 </p>
1477 </div>
1478 <hr>
1479 <div class="refsect2" title="g_test_create_case ()">
1480 <a name="g-test-create-case"></a><h3>g_test_create_case ()</h3>
1481 <pre class="programlisting"><a class="link" href="glib-Testing.html#GTestCase" title="GTestCase"><span class="returnvalue">GTestCase</span></a>*          g_test_create_case                  (const <span class="returnvalue">char</span> *test_name,
1482                                                          <a class="link" href="glib-Basic-Types.html#gsize" title="gsize"><span class="returnvalue">gsize</span></a> data_size,
1483                                                          <a class="link" href="glib-Basic-Types.html#gconstpointer" title="gconstpointer"><span class="returnvalue">gconstpointer</span></a> test_data,
1484                                                          <span class="returnvalue">void</span> (data_setupvoid) (),
1485                                                          <span class="returnvalue">void</span> (data_testvoid) (),
1486                                                          <span class="returnvalue">void</span> (data_teardownvoid) ());</pre>
1487 <p>
1488 Create a new <a class="link" href="glib-Testing.html#GTestCase" title="GTestCase"><span class="type">GTestCase</span></a>, named <em class="parameter"><code>test_name</code></em>, this API is fairly
1489 low level, calling <a class="link" href="glib-Testing.html#g-test-add" title="g_test_add()"><code class="function">g_test_add()</code></a> or <a class="link" href="glib-Testing.html#g-test-add-func" title="g_test_add_func ()"><code class="function">g_test_add_func()</code></a> is preferable.
1490 When this test is executed, a fixture structure of size <em class="parameter"><code>data_size</code></em>
1491 will be allocated and filled with 0s. Then <code class="function">data_setup()</code> is called
1492 to initialize the fixture. After fixture setup, the actual test
1493 function <code class="function">data_test()</code> is called. Once the test run completed, the
1494 fixture structure is torn down  by calling <code class="function">data_teardown()</code> and
1495 after that the memory is released.
1496 </p>
1497 <p>
1498 Splitting up a test run into fixture setup, test function and
1499 fixture teardown is most usful if the same fixture is used for
1500 multiple tests. In this cases, <a class="link" href="glib-Testing.html#g-test-create-case" title="g_test_create_case ()"><code class="function">g_test_create_case()</code></a> will be
1501 called with the same fixture, but varying <em class="parameter"><code>test_name</code></em> and
1502 <em class="parameter"><code>data_test</code></em> arguments.</p>
1503 <div class="variablelist"><table border="0">
1504 <col align="left" valign="top">
1505 <tbody>
1506 <tr>
1507 <td><p><span class="term"><em class="parameter"><code>test_name</code></em> :</span></p></td>
1508 <td>     the name for the test case
1509 </td>
1510 </tr>
1511 <tr>
1512 <td><p><span class="term"><em class="parameter"><code>data_size</code></em> :</span></p></td>
1513 <td>     the size of the fixture data structure
1514 </td>
1515 </tr>
1516 <tr>
1517 <td><p><span class="term"><em class="parameter"><code>test_data</code></em> :</span></p></td>
1518 <td>     test data argument for the test functions
1519 </td>
1520 </tr>
1521 <tr>
1522 <td><p><span class="term"><em class="parameter"><code>data_setup</code></em> :</span></p></td>
1523 <td>    the function to set up the fixture data
1524 </td>
1525 </tr>
1526 <tr>
1527 <td><p><span class="term"><em class="parameter"><code>data_test</code></em> :</span></p></td>
1528 <td>     the actual test function
1529 </td>
1530 </tr>
1531 <tr>
1532 <td><p><span class="term"><em class="parameter"><code>data_teardown</code></em> :</span></p></td>
1533 <td> the function to teardown the fixture data
1534 </td>
1535 </tr>
1536 <tr>
1537 <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
1538 <td> a newly allocated <a class="link" href="glib-Testing.html#GTestCase" title="GTestCase"><span class="type">GTestCase</span></a>.
1539
1540 </td>
1541 </tr>
1542 </tbody>
1543 </table></div>
1544 <p class="since">Since 2.16</p>
1545 </div>
1546 <hr>
1547 <div class="refsect2" title="g_test_create_suite ()">
1548 <a name="g-test-create-suite"></a><h3>g_test_create_suite ()</h3>
1549 <pre class="programlisting"><a class="link" href="glib-Testing.html#GTestSuite" title="GTestSuite"><span class="returnvalue">GTestSuite</span></a>*         g_test_create_suite                 (const <span class="returnvalue">char</span> *suite_name);</pre>
1550 <p>
1551 Create a new test suite with the name <em class="parameter"><code>suite_name</code></em>.</p>
1552 <div class="variablelist"><table border="0">
1553 <col align="left" valign="top">
1554 <tbody>
1555 <tr>
1556 <td><p><span class="term"><em class="parameter"><code>suite_name</code></em> :</span></p></td>
1557 <td> a name for the suite
1558 </td>
1559 </tr>
1560 <tr>
1561 <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
1562 <td> A newly allocated <a class="link" href="glib-Testing.html#GTestSuite" title="GTestSuite"><span class="type">GTestSuite</span></a> instance.
1563
1564 </td>
1565 </tr>
1566 </tbody>
1567 </table></div>
1568 <p class="since">Since 2.16</p>
1569 </div>
1570 <hr>
1571 <div class="refsect2" title="g_test_get_root ()">
1572 <a name="g-test-get-root"></a><h3>g_test_get_root ()</h3>
1573 <pre class="programlisting"><a class="link" href="glib-Testing.html#GTestSuite" title="GTestSuite"><span class="returnvalue">GTestSuite</span></a>*         g_test_get_root                     (void);</pre>
1574 <p>
1575 Get the toplevel test suite for the test path API.</p>
1576 <div class="variablelist"><table border="0">
1577 <col align="left" valign="top">
1578 <tbody><tr>
1579 <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
1580 <td> the toplevel <a class="link" href="glib-Testing.html#GTestSuite" title="GTestSuite"><span class="type">GTestSuite</span></a>
1581
1582 </td>
1583 </tr></tbody>
1584 </table></div>
1585 <p class="since">Since 2.16</p>
1586 </div>
1587 <hr>
1588 <div class="refsect2" title="g_test_suite_add ()">
1589 <a name="g-test-suite-add"></a><h3>g_test_suite_add ()</h3>
1590 <pre class="programlisting"><span class="returnvalue">void</span>                g_test_suite_add                    (<a class="link" href="glib-Testing.html#GTestSuite" title="GTestSuite"><span class="returnvalue">GTestSuite</span></a> *suite,
1591                                                          <a class="link" href="glib-Testing.html#GTestCase" title="GTestCase"><span class="returnvalue">GTestCase</span></a> *test_case);</pre>
1592 <p>
1593 Adds <em class="parameter"><code>test_case</code></em> to <em class="parameter"><code>suite</code></em>.</p>
1594 <div class="variablelist"><table border="0">
1595 <col align="left" valign="top">
1596 <tbody>
1597 <tr>
1598 <td><p><span class="term"><em class="parameter"><code>suite</code></em> :</span></p></td>
1599 <td> a <a class="link" href="glib-Testing.html#GTestSuite" title="GTestSuite"><span class="type">GTestSuite</span></a>
1600 </td>
1601 </tr>
1602 <tr>
1603 <td><p><span class="term"><em class="parameter"><code>test_case</code></em> :</span></p></td>
1604 <td> a <a class="link" href="glib-Testing.html#GTestCase" title="GTestCase"><span class="type">GTestCase</span></a>
1605 </td>
1606 </tr>
1607 </tbody>
1608 </table></div>
1609 <p class="since">Since 2.16</p>
1610 </div>
1611 <hr>
1612 <div class="refsect2" title="g_test_suite_add_suite ()">
1613 <a name="g-test-suite-add-suite"></a><h3>g_test_suite_add_suite ()</h3>
1614 <pre class="programlisting"><span class="returnvalue">void</span>                g_test_suite_add_suite              (<a class="link" href="glib-Testing.html#GTestSuite" title="GTestSuite"><span class="returnvalue">GTestSuite</span></a> *suite,
1615                                                          <a class="link" href="glib-Testing.html#GTestSuite" title="GTestSuite"><span class="returnvalue">GTestSuite</span></a> *nestedsuite);</pre>
1616 <p>
1617 Adds <em class="parameter"><code>nestedsuite</code></em> to <em class="parameter"><code>suite</code></em>.</p>
1618 <div class="variablelist"><table border="0">
1619 <col align="left" valign="top">
1620 <tbody>
1621 <tr>
1622 <td><p><span class="term"><em class="parameter"><code>suite</code></em> :</span></p></td>
1623 <td>       a <a class="link" href="glib-Testing.html#GTestSuite" title="GTestSuite"><span class="type">GTestSuite</span></a>
1624 </td>
1625 </tr>
1626 <tr>
1627 <td><p><span class="term"><em class="parameter"><code>nestedsuite</code></em> :</span></p></td>
1628 <td> another <a class="link" href="glib-Testing.html#GTestSuite" title="GTestSuite"><span class="type">GTestSuite</span></a>
1629 </td>
1630 </tr>
1631 </tbody>
1632 </table></div>
1633 <p class="since">Since 2.16</p>
1634 </div>
1635 <hr>
1636 <div class="refsect2" title="g_test_run_suite ()">
1637 <a name="g-test-run-suite"></a><h3>g_test_run_suite ()</h3>
1638 <pre class="programlisting"><span class="returnvalue">int</span>                 g_test_run_suite                    (<a class="link" href="glib-Testing.html#GTestSuite" title="GTestSuite"><span class="returnvalue">GTestSuite</span></a> *suite);</pre>
1639 <p>
1640 Execute the tests within <em class="parameter"><code>suite</code></em> and all nested <a href="glib-Testing.html#GTestSuite"><span class="type">GTestSuites</span></a>.
1641 The test suites to be executed are filtered according to
1642 test path arguments (-p <em class="replaceable"><code>testpath</code></em>) 
1643 as parsed by <a class="link" href="glib-Testing.html#g-test-init" title="g_test_init ()"><code class="function">g_test_init()</code></a>.
1644 <a class="link" href="glib-Testing.html#g-test-run-suite" title="g_test_run_suite ()"><code class="function">g_test_run_suite()</code></a> or <a class="link" href="glib-Testing.html#g-test-run" title="g_test_run ()"><code class="function">g_test_run()</code></a> may only be called once
1645 in a program.</p>
1646 <div class="variablelist"><table border="0">
1647 <col align="left" valign="top">
1648 <tbody>
1649 <tr>
1650 <td><p><span class="term"><em class="parameter"><code>suite</code></em> :</span></p></td>
1651 <td> a <a class="link" href="glib-Testing.html#GTestSuite" title="GTestSuite"><span class="type">GTestSuite</span></a>
1652 </td>
1653 </tr>
1654 <tr>
1655 <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
1656 <td> 0 on success
1657
1658 </td>
1659 </tr>
1660 </tbody>
1661 </table></div>
1662 <p class="since">Since 2.16</p>
1663 </div>
1664 </div>
1665 <div class="refsect1" title="See Also">
1666 <a name="glib-Testing.see-also"></a><h2>See Also</h2>
1667 <p>
1668 <a href="gtester.html">gtester</a>,
1669 <a href="gtester-report.html">gtester-report</a>
1670 </p>
1671 </div>
1672 </div>
1673 <div class="footer">
1674 <hr>
1675           Generated by GTK-Doc V1.13</div>
1676 </body>
1677 </html>