sc/qa/unit/subsequent_export-test.cxx | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-)
New commits: commit 8e500c458af5f5ec7c680cd4ad083d8798c459a2 Author: Mark Hung <mark...@gmail.com> AuthorDate: Fri Jan 3 23:50:01 2020 +0800 Commit: Mike Kaganski <mike.kagan...@collabora.com> CommitDate: Sat Jan 4 07:07:04 2020 +0100 sc/qa: revert locale change in the scope guard. ScExportTest::testTdf112567() and ScExportTest::testTdf112567b() change the locale config to "hu-HU" and revert to "" at the end, the resulted locale is the system one instead of English, and breaks testTdf128976 under a zh-TW build environment because testTdf128976 relies on some font/loclae dependent metric data. Change-Id: Iec8a0771a726133dfd30d5e5e254d9b678d44d72 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/86191 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kagan...@collabora.com> diff --git a/sc/qa/unit/subsequent_export-test.cxx b/sc/qa/unit/subsequent_export-test.cxx index 38f024ae22a4..c9e15f8514c7 100644 --- a/sc/qa/unit/subsequent_export-test.cxx +++ b/sc/qa/unit/subsequent_export-test.cxx @@ -4429,10 +4429,11 @@ void ScExportTest::testTdf112567() { // Set the system locale to Hungarian (a language with different range separator) SvtSysLocaleOptions aOptions; + OUString sLocaleConfigString = aOptions.GetLanguageTag().getBcp47(); aOptions.SetLocaleConfigString("hu-HU"); aOptions.Commit(); - comphelper::ScopeGuard g([&aOptions] { - aOptions.SetLocaleConfigString(OUString()); + comphelper::ScopeGuard g([&aOptions, &sLocaleConfigString] { + aOptions.SetLocaleConfigString(sLocaleConfigString); aOptions.Commit(); }); @@ -4455,10 +4456,11 @@ void ScExportTest::testTdf112567b() { // Set the system locale to Hungarian (a language with different range separator) SvtSysLocaleOptions aOptions; + OUString sLocaleConfigString = aOptions.GetLanguageTag().getBcp47(); aOptions.SetLocaleConfigString("hu-HU"); aOptions.Commit(); - comphelper::ScopeGuard g([&aOptions] { - aOptions.SetLocaleConfigString(OUString()); + comphelper::ScopeGuard g([&aOptions, &sLocaleConfigString] { + aOptions.SetLocaleConfigString(sLocaleConfigString); aOptions.Commit(); }); _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits