Fix leftover locale.getdefaultlocale mock

Replace the remaining `locale.getdefaultlocale` mock with
`locale.getlocale`.  77a994a993 has
replaced the `locale.getdefaultlocale()` call and updated all other
mocks but this one remained, causing test failures on non-en_US locales.

Closes-Bug: 2043539
Change-Id: I5ab36a0ead05fa7a83fc1c64e440482f2cc8e675
Signed-off-by: Michał Górny <mgorny@gentoo.org>
This commit is contained in:
Michał Górny 2023-11-15 09:16:21 +01:00
parent 4bcda7821b
commit 151fa09cf0

View File

@ -160,5 +160,5 @@ class PrefixLazyTranslation(fixtures.Fixture):
lambda *x, **y: self.languages))
self.useFixture(fixtures.MonkeyPatch('gettext.translation',
_prefix_translations))
self.useFixture(fixtures.MonkeyPatch('locale.getdefaultlocale',
self.useFixture(fixtures.MonkeyPatch('locale.getlocale',
lambda *x, **y: self.locale))