We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 7b98ba8 commit d9ae563Copy full SHA for d9ae563
Lib/test/test_tools/test_i18n.py
@@ -464,6 +464,17 @@ def test_comments_with_multiple_tags(self):
464
self.assertIn('#. foo: comment', data)
465
self.assertIn('#. bar: comment', data)
466
467
+ def test_comments_not_extracted_without_tags(self):
468
+ """
469
+ Test that translator comments are not extracted without
470
+ specifying --add-comments.
471
472
+ data = self.extract_from_str(dedent('''\
473
+ # Translator comment
474
+ _("foo")
475
+ '''), raw=True)
476
+ self.assertNotIn('#.', data)
477
+
478
479
def update_POT_snapshots():
480
for input_file in DATA_DIR.glob('*.py'):
0 commit comments