本文整理汇总了Python中tagger.Tagger.getTagsForCommand方法的典型用法代码示例。如果您正苦于以下问题:Python Tagger.getTagsForCommand方法的具体用法?Python Tagger.getTagsForCommand怎么用?Python Tagger.getTagsForCommand使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类tagger.Tagger
的用法示例。
在下文中一共展示了Tagger.getTagsForCommand方法的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: testTaggerColorTags
# 需要导入模块: from tagger import Tagger [as 别名]
# 或者: from tagger.Tagger import getTagsForCommand [as 别名]
def testTaggerColorTags(self):
self.assertEqual(Tagger.getTagsForCommand('color:FF0000'), ('<font color=#FF0000>', '</font>'))
示例2: testTaggerNegativeSizeError
# 需要导入模块: from tagger import Tagger [as 别名]
# 或者: from tagger.Tagger import getTagsForCommand [as 别名]
def testTaggerNegativeSizeError(self):
with self.assertRaises(SystemExit) as exit_val:
Tagger.getTagsForCommand('size:-1')
self.assertEqual(exit_val.exception.code, 4)
示例3: testTaggerSizeTags
# 需要导入模块: from tagger import Tagger [as 别名]
# 或者: from tagger.Tagger import getTagsForCommand [as 别名]
def testTaggerSizeTags(self):
self.assertEqual(Tagger.getTagsForCommand('size:4'), ('<font size=4>', '</font>'))
示例4: testTaggerTeletypeTags
# 需要导入模块: from tagger import Tagger [as 别名]
# 或者: from tagger.Tagger import getTagsForCommand [as 别名]
def testTaggerTeletypeTags(self):
self.assertEqual(Tagger.getTagsForCommand('teletype'), ('<tt>', '</tt>'))
示例5: testTaggerUnderlineTags
# 需要导入模块: from tagger import Tagger [as 别名]
# 或者: from tagger.Tagger import getTagsForCommand [as 别名]
def testTaggerUnderlineTags(self):
self.assertEqual(Tagger.getTagsForCommand('underline'), ('<u>', '</u>'))
示例6: testTaggerItalicTags
# 需要导入模块: from tagger import Tagger [as 别名]
# 或者: from tagger.Tagger import getTagsForCommand [as 别名]
def testTaggerItalicTags(self):
self.assertEqual(Tagger.getTagsForCommand('italic'), ('<i>', '</i>'))
示例7: testTaggerBoldTags
# 需要导入模块: from tagger import Tagger [as 别名]
# 或者: from tagger.Tagger import getTagsForCommand [as 别名]
def testTaggerBoldTags(self):
self.assertEqual(Tagger.getTagsForCommand('bold'), ('<b>', '</b>'))