diff options
Diffstat (limited to 'tests/template_tests/syntax_tests/i18n/test_blocktrans.py')
| -rw-r--r-- | tests/template_tests/syntax_tests/i18n/test_blocktrans.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/tests/template_tests/syntax_tests/i18n/test_blocktrans.py b/tests/template_tests/syntax_tests/i18n/test_blocktrans.py index ac8fc16da8..744b410ea6 100644 --- a/tests/template_tests/syntax_tests/i18n/test_blocktrans.py +++ b/tests/template_tests/syntax_tests/i18n/test_blocktrans.py @@ -1,5 +1,6 @@ import os -from threading import local + +from asgiref.local import Local from django.template import Context, Template, TemplateSyntaxError from django.test import SimpleTestCase, override_settings @@ -278,7 +279,7 @@ class TranslationBlockTransTagTests(SimpleTestCase): @override_settings(LOCALE_PATHS=extended_locale_paths) def test_template_tags_pgettext(self): """{% blocktrans %} takes message contexts into account (#14806).""" - trans_real._active = local() + trans_real._active = Local() trans_real._translations = {} with translation.override('de'): # Nonexistent context |
