本文整理汇总了Python中nose.config.Config.help方法的典型用法代码示例。如果您正苦于以下问题:Python Config.help方法的具体用法?Python Config.help怎么用?Python Config.help使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类nose.config.Config
的用法示例。
在下文中一共展示了Config.help方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: usage
# 需要导入模块: from nose.config import Config [as 别名]
# 或者: from nose.config.Config import help [as 别名]
def usage():
conf = Config(plugins=BuiltinPluginManager())
usage_text = conf.help(nose.main.__doc__).replace('mkwiki.py', 'nosetests')
out = '{{{\n%s\n}}}\n' % usage_text
return out
示例2: print
# 需要导入模块: from nose.config import Config [as 别名]
# 或者: from nose.config.Config import help [as 别名]
print("Commands...")
cmds = publish_parts(nose.commands.__doc__, reader=DocReader(),
writer_name='html')
docs['commands'] = cmds['body']
print("Changelog...")
changes = open(os.path.join(root, 'CHANGELOG'), 'r').read()
changes_html = publish_parts(changes, reader=DocReader(), writer_name='html')
docs['changelog'] = changes_html['body']
print("News...")
news = open(os.path.join(root, 'NEWS'), 'r').read()
news_html = publish_parts(news, reader=DocReader(), writer_name='html')
docs['news'] = news_html['body']
print("Usage...")
conf = Config(plugins=BuiltinPluginManager())
usage_txt = conf.help(nose.main.__doc__).replace(
'mkindex.py', 'nosetests')
docs['usage'] = '<pre>%s</pre>' % usage_txt
out = tpl % docs
index = open(os.path.join(root, 'index.html'), 'w')
index.write(out)
index.close()
readme = open(os.path.join(root, 'README.txt'), 'w')
readme.write(nose.__doc__)
readme.close()