mirror of
https://github.com/Gnucash/gnucash.git
synced 2025-02-25 18:55:30 -06:00
Disable tests when minimum glib2 requirement is not met
These tests use g_assert_true which is available as of glib2 2.38 only.
This commit is contained in:
parent
a63a4d5e8a
commit
3f42569541
@ -49,6 +49,9 @@ teardown (Fixture *fixture, gconstpointer pData)
|
|||||||
test_clear_error_list();
|
test_clear_error_list();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* The exluded tests all rely on g_assert_true wich was only introduced
|
||||||
|
* in glib 2.38 */
|
||||||
|
#ifdef HAVE_GLIB_2_38
|
||||||
static void
|
static void
|
||||||
test_pending_matches_match_types (Fixture *fixture, gconstpointer pData)
|
test_pending_matches_match_types (Fixture *fixture, gconstpointer pData)
|
||||||
{
|
{
|
||||||
@ -111,6 +114,7 @@ test_pending_matches_keeps_count (Fixture *fixture, gconstpointer pData)
|
|||||||
|
|
||||||
gnc_import_PendingMatches_delete (matches);
|
gnc_import_PendingMatches_delete (matches);
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
int
|
int
|
||||||
main (int argc, char *argv[])
|
main (int argc, char *argv[])
|
||||||
@ -119,12 +123,16 @@ main (int argc, char *argv[])
|
|||||||
qof_init();
|
qof_init();
|
||||||
g_test_init (&argc, &argv, NULL);
|
g_test_init (&argc, &argv, NULL);
|
||||||
|
|
||||||
|
/* The exluded tests all rely on g_assert_true wich was only introduced
|
||||||
|
* in glib 2.38 */
|
||||||
|
#ifdef HAVE_GLIB_2_38
|
||||||
GNC_TEST_ADD (suitename, "match_types", Fixture, NULL, setup,
|
GNC_TEST_ADD (suitename, "match_types", Fixture, NULL, setup,
|
||||||
test_pending_matches_match_types, teardown);
|
test_pending_matches_match_types, teardown);
|
||||||
GNC_TEST_ADD (suitename, "prefer_manual_match", Fixture, NULL, setup,
|
GNC_TEST_ADD (suitename, "prefer_manual_match", Fixture, NULL, setup,
|
||||||
test_pending_matches_prefer_manual_match, teardown);
|
test_pending_matches_prefer_manual_match, teardown);
|
||||||
GNC_TEST_ADD (suitename, "keeps_count", Fixture, NULL, setup,
|
GNC_TEST_ADD (suitename, "keeps_count", Fixture, NULL, setup,
|
||||||
test_pending_matches_keeps_count, teardown);
|
test_pending_matches_keeps_count, teardown);
|
||||||
|
#endif
|
||||||
result = g_test_run();
|
result = g_test_run();
|
||||||
|
|
||||||
qof_close();
|
qof_close();
|
||||||
|
Loading…
Reference in New Issue
Block a user