test: add test for fallback behavior

This commit is contained in:
AarDG10 2026-03-13 11:58:18 +05:30
parent 3e14434f9e
commit d71fde349b

View file

@ -92,6 +92,12 @@ class TestTranslation(IntegrationTestCase):
self.assertTrue(_(source), target)
def test_html_message_translations(self):
"""Test fallback for messages w/ HTML Tags"""
message = "Hide descendant records of <b>For Value</b>."
translated_message = "隐藏下层节点<b>值</b>"
self.assertEqual(_(message, lang="zh"), translated_message)
def get_translation_data():
html_source_data = """<font color="#848484" face="arial, tahoma, verdana, sans-serif">