From 0fbcaa7ccae344627f4c901723dc5d82319687ad Mon Sep 17 00:00:00 2001 From: Matthias Clasen Date: Sat, 21 Aug 2021 22:18:02 -0400 Subject: tests: Make test-itemize work better This wasn't working when passed a file on the commandline. Fix that. --- tests/test-itemize.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'tests') diff --git a/tests/test-itemize.c b/tests/test-itemize.c index 0a8515b8..926eb3ae 100644 --- a/tests/test-itemize.c +++ b/tests/test-itemize.c @@ -251,8 +251,6 @@ test_itemize (gconstpointer d) return; } - context = pango_font_map_create_context (pango_cairo_font_map_get_default ()); - found_cantarell = FALSE; pango_context_list_families (context, &families, &n_families); for (int i = 0; i < n_families; i++) @@ -305,7 +303,6 @@ test_itemize (gconstpointer d) g_free (diff); g_string_free (dump, TRUE); g_free (expected_file); - g_object_unref (context); } int @@ -318,6 +315,9 @@ main (int argc, char *argv[]) g_test_init (&argc, &argv, NULL); + context = pango_font_map_create_context (pango_cairo_font_map_get_default ()); + pango_context_set_language (context, pango_language_from_string ("en-us")); + /* allow to easily generate expected output for new test cases */ if (argc > 1) { -- cgit v1.2.1