Fixed isolation of i18n.tests.FormattingTests.test_get_custom_format().

This commit is contained in:
Mariusz Felisiak 2021-04-22 19:57:27 +02:00 committed by GitHub
parent 90916f050c
commit ac2e6e6869
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 0 deletions

View File

@ -1254,6 +1254,7 @@ class FormattingTests(SimpleTestCase):
self.assertEqual(get_format('DEBUG'), 'DEBUG')
def test_get_custom_format(self):
reset_format_cache()
with self.settings(FORMAT_MODULE_PATH='i18n.other.locale'):
with translation.override('fr', deactivate=True):
self.assertEqual('d/m/Y CUSTOM', get_format('CUSTOM_DAY_FORMAT'))