mirror of
https://github.com/django/django.git
synced 2025-09-16 07:25:18 +00:00
Refs #30372 -- Stopped watching built-in Django translation files by auto-reloader.
This commit is contained in:
parent
8f10ceaa90
commit
c00bc27945
3 changed files with 19 additions and 1 deletions
|
@ -1865,6 +1865,12 @@ class WatchForTranslationChangesTests(SimpleTestCase):
|
|||
project_dir = Path(__file__).parent / 'sampleproject' / 'locale'
|
||||
mocked_sender.watch_dir.assert_any_call(project_dir, '**/*.mo')
|
||||
|
||||
def test_i18n_app_dirs_ignore_django_apps(self):
|
||||
mocked_sender = mock.MagicMock()
|
||||
with self.settings(INSTALLED_APPS=['django.contrib.admin']):
|
||||
watch_for_translation_changes(mocked_sender)
|
||||
mocked_sender.watch_dir.assert_called_once_with(Path('locale'), '**/*.mo')
|
||||
|
||||
def test_i18n_local_locale(self):
|
||||
mocked_sender = mock.MagicMock()
|
||||
watch_for_translation_changes(mocked_sender)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue