[gnome-desktop/wip/hadess/fix-ci] tests: Check that setting the locale worked



commit cda19ded7646644e920ba665a6d5a8342b06f75c
Author: Bastien Nocera <hadess hadess net>
Date:   Tue Jan 29 12:21:10 2019 +0100

    tests: Check that setting the locale worked

 tests/wallclock-reftest.c | 9 +++++++--
 1 file changed, 7 insertions(+), 2 deletions(-)
---
diff --git a/tests/wallclock-reftest.c b/tests/wallclock-reftest.c
index fe71b5a5..50e614bd 100644
--- a/tests/wallclock-reftest.c
+++ b/tests/wallclock-reftest.c
@@ -438,13 +438,18 @@ test_ui_file (GFile         *file,
   GtkStyleProvider *provider;
   GnomeWallClock *clock;
   GDateTime *datetime;
-  char *str;
+  char *str, *set_locale;
 
   ui_file = g_file_get_path (file);
 
   locale = get_locale_for_file (ui_file);
   g_assert (locale);
-  setlocale (LC_ALL, locale);
+  set_locale = setlocale (LC_ALL, locale);
+  g_assert_cmpstr (set_locale, ==, locale);
+//  set_locale = setlocale (LC_TIME, locale);
+//  g_assert_cmpstr (set_locale, ==, locale);
+//  set_locale = setlocale (LC_MESSAGES, locale);
+//  g_assert_cmpstr (set_locale, ==, locale);
 
   clock = gnome_wall_clock_new();
   datetime = g_date_time_new_local (2014, 5, 28, 23, 59, 59);


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]