qmimetype: Fix test failure when LC_ALL is set.

This code sets LANG=en_US so that the method comment(), which returns a translated
name, can be compared with an expected result in English.
(QMimeType::comment uses QLocale::system().name() and QLocale::system().uiLanguages())

But LANG= has no effect if LC_ALL is set, so LC_ALL needs to be cleared (or set
to en_US) for the test to work.

Change-Id: Icb031057769be9bc8c0fcab65daa45e7bf1d5b18
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
This commit is contained in:
David Faure 2012-02-20 18:14:55 +01:00 committed by Qt by Nokia
parent 3f91cde588
commit 848d3694f6

View File

@ -51,6 +51,7 @@
void initializeLang()
{
qputenv("LC_ALL", "");
qputenv("LANG", "en_US");
}