def test_format_related_forms(self): entry = LexicalEntry() entry.create_and_add_related_form("syn", mdf_semanticRelation["sy"]) entry.create_and_add_related_form("ant", mdf_semanticRelation["an"]) entry.set_morphology("morph") entry.create_and_add_related_form("see", mdf_semanticRelation["cf"]) expected = "\\textit{Syn:} \\textbf{\ipa{syn}}. \\textit{Ant:} \\textbf{\ipa{ant}}. \\textit{Morph:} \\textbf{\ipa{morph}}. \\textit{See:} \\textbf{\ipa{see}} " self.assertEqual(format_related_forms(entry, font), expected) del entry