mirror of
https://github.com/django/django.git
synced 2025-10-26 15:16:09 +00:00
Made (make|compile)messages check for availability of gettext commands.
Refs #19584.
This commit is contained in:
@@ -131,8 +131,13 @@ class BasicExtractorTests(ExtractorTests):
|
||||
os.chdir(self.test_dir)
|
||||
shutil.copyfile('./code.sample', './code_sample.py')
|
||||
stdout = StringIO()
|
||||
management.call_command('makemessages', locale=LOCALE, stdout=stdout)
|
||||
os.remove('./code_sample.py')
|
||||
try:
|
||||
management.call_command('makemessages', locale=LOCALE, stdout=stdout)
|
||||
finally:
|
||||
try:
|
||||
os.remove('./code_sample.py')
|
||||
except OSError:
|
||||
pass
|
||||
self.assertIn("code_sample.py:4", force_text(stdout.getvalue()))
|
||||
|
||||
def test_template_message_context_extractor(self):
|
||||
|
||||
Reference in New Issue
Block a user