diff --git a/cms/djangoapps/contentstore/tests/test_i18n.py b/cms/djangoapps/contentstore/tests/test_i18n.py index db0ed7e04d4..dc774030716 100644 --- a/cms/djangoapps/contentstore/tests/test_i18n.py +++ b/cms/djangoapps/contentstore/tests/test_i18n.py @@ -118,7 +118,6 @@ def __exit__(self, _type, _value, _traceback): # Check that the old ugettext has been put back into place self.assertEqual(i18n_service.ugettext(self.test_language), 'dummy language') - @mock.patch('django.utils.translation.ugettext', mock.Mock(return_value='XYZ-TEST-LANGUAGE')) @mock.patch('django.utils.translation.gettext', mock.Mock(return_value='XYZ-TEST-LANGUAGE')) def test_django_translator_in_use_with_empty_block(self): """ @@ -127,7 +126,7 @@ def test_django_translator_in_use_with_empty_block(self): i18n_service = XBlockI18nService(None) self.assertEqual(i18n_service.ugettext(self.test_language), 'XYZ-TEST-LANGUAGE') - @mock.patch('django.utils.translation.ugettext', mock.Mock(return_value='XYZ-TEST-LANGUAGE')) + @mock.patch('django.utils.translation.gettext', mock.Mock(return_value='XYZ-TEST-LANGUAGE')) def test_message_catalog_translations(self): """ Test: Message catalog from FakeTranslation should return required translations. diff --git a/lms/templates/dashboard/_dashboard_course_listing.html b/lms/templates/dashboard/_dashboard_course_listing.html index ac34e4cbc32..39c66f0e81f 100644 --- a/lms/templates/dashboard/_dashboard_course_listing.html +++ b/lms/templates/dashboard/_dashboard_course_listing.html @@ -7,7 +7,7 @@ from django.utils.http import urlencode from urllib.parse import quote_plus from django.utils.translation import gettext as _ -from django.utils.translation import ungettext +from django.utils.translation import ngettext from django.urls import reverse from common.djangoapps.course_modes.models import CourseMode from common.djangoapps.course_modes.helpers import enrollment_mode_display diff --git a/lms/templates/discussion/_user_profile.html b/lms/templates/discussion/_user_profile.html index d1910919fe5..dc8d7051313 100644 --- a/lms/templates/discussion/_user_profile.html +++ b/lms/templates/discussion/_user_profile.html @@ -1,10 +1,10 @@ -<%! from django.utils.translation import gettext as _, ungettext %> +<%! from django.utils.translation import gettext as _, ngettext %> <%def name="span(num)">${num}%def>