Title: [145509] releases/WebKitGTK/webkit-2.0/Source/WebKit2
Revision
145509
Author
carlo...@webkit.org
Date
2013-03-12 03:12:05 -0700 (Tue, 12 Mar 2013)

Log Message

Merge r145508 - [GTK][WK2] REGRESSION(r145081): Unit tests not working if locale is not English
https://bugs.webkit.org/show_bug.cgi?id=111973

Patch by Manuel Rego Casasnovas <r...@igalia.com> on 2013-03-12
Reviewed by Carlos Garcia Campos.

The problem is that the UIProcess locale is reseted to C in
gtk_test_init, however the WebProcess does not inherit the locale set in
the UIProcess and it uses the system one (that could be different to
English). So, there were problems in some tests that are comparing
strings from both processes like WebKit2APITests/TestPrinting and
WebKit2APITests/TestWebKitWebContext. The solution is to set the locale
environment variable LC_ALL to C in order to reset WebProcess locale
too.

* UIProcess/API/gtk/tests/TestMain.cpp:
(main): Set environment variable LC_ALL to C.

Modified Paths

Diff

Modified: releases/WebKitGTK/webkit-2.0/Source/WebKit2/ChangeLog (145508 => 145509)


--- releases/WebKitGTK/webkit-2.0/Source/WebKit2/ChangeLog	2013-03-12 10:07:32 UTC (rev 145508)
+++ releases/WebKitGTK/webkit-2.0/Source/WebKit2/ChangeLog	2013-03-12 10:12:05 UTC (rev 145509)
@@ -1,3 +1,22 @@
+2013-03-12  Manuel Rego Casasnovas  <r...@igalia.com>
+
+        [GTK][WK2] REGRESSION(r145081): Unit tests not working if locale is not English
+        https://bugs.webkit.org/show_bug.cgi?id=111973
+
+        Reviewed by Carlos Garcia Campos.
+
+        The problem is that the UIProcess locale is reseted to C in
+        gtk_test_init, however the WebProcess does not inherit the locale set in
+        the UIProcess and it uses the system one (that could be different to
+        English). So, there were problems in some tests that are comparing
+        strings from both processes like WebKit2APITests/TestPrinting and
+        WebKit2APITests/TestWebKitWebContext. The solution is to set the locale
+        environment variable LC_ALL to C in order to reset WebProcess locale
+        too.
+
+        * UIProcess/API/gtk/tests/TestMain.cpp:
+        (main): Set environment variable LC_ALL to C.
+
 2013-03-11  Manuel Rego Casasnovas  <r...@igalia.com>
 
         WebKitWebPage::document-loaded signal emitted multiple times

Modified: releases/WebKitGTK/webkit-2.0/Source/WebKit2/UIProcess/API/gtk/tests/TestMain.cpp (145508 => 145509)


--- releases/WebKitGTK/webkit-2.0/Source/WebKit2/UIProcess/API/gtk/tests/TestMain.cpp	2013-03-12 10:07:32 UTC (rev 145508)
+++ releases/WebKitGTK/webkit-2.0/Source/WebKit2/UIProcess/API/gtk/tests/TestMain.cpp	2013-03-12 10:12:05 UTC (rev 145509)
@@ -40,6 +40,7 @@
     gtk_test_init(&argc, &argv, 0);
     g_setenv("WEBKIT_EXEC_PATH", WEBKIT_EXEC_PATH, FALSE);
     g_setenv("WEBKIT_INJECTED_BUNDLE_PATH", WEBKIT_INJECTED_BUNDLE_PATH, FALSE);
+    g_setenv("LC_ALL", "C", TRUE);
     g_test_bug_base("https://bugs.webkit.org/");
 
     registerGResource();
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to