本文整理汇总了Python中Acspy.Common.Log.getLoggerNames方法的典型用法代码示例。如果您正苦于以下问题:Python Log.getLoggerNames方法的具体用法?Python Log.getLoggerNames怎么用?Python Log.getLoggerNames使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Acspy.Common.Log
的用法示例。
在下文中一共展示了Log.getLoggerNames方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: get_logger_names
# 需要导入模块: from Acspy.Common import Log [as 别名]
# 或者: from Acspy.Common.Log import getLoggerNames [as 别名]
def get_logger_names(self): # pragma: NO COVER
'''
Retrieve the names of the currently active loggers
Returns: list of logger name strings
'''
return Log.getLoggerNames()
示例2: testLoggerNamesRequestedFiltered
# 需要导入模块: from Acspy.Common import Log [as 别名]
# 或者: from Acspy.Common.Log import getLoggerNames [as 别名]
def testLoggerNamesRequestedFiltered(self):
"""SeveralLoggerCheck getLoggerNames returns correct logger names when requested with filtering"""
self.assertEquals(True, self.cname in Log.getLoggerNames(self.pname[:-1]))
self.assertEquals(True, self.pname in Log.getLoggerNames(self.pname[:-1]))
self.assertEquals([self.cname], Log.getLoggerNames(self.cname))
示例3: testLoggerNamesRequested
# 需要导入模块: from Acspy.Common import Log [as 别名]
# 或者: from Acspy.Common.Log import getLoggerNames [as 别名]
def testLoggerNamesRequested(self):
"""SeveralLoggerCheck getLoggerNames returns all known loggers"""
self.assertEquals(Log.logging.Logger.manager.loggerDict.keys(), Log.getLoggerNames())
示例4: testUnnamedLoggerNamesList
# 需要导入模块: from Acspy.Common import Log [as 别名]
# 或者: from Acspy.Common.Log import getLoggerNames [as 别名]
def testUnnamedLoggerNamesList(self):
"""OneLoggerCheck names list has unnamed logger when filtered by unnamed logger"""
self.assertEquals([self.mylogger.name], Log.getLoggerNames(self.mylogger.name))
示例5: testGetLoggerNames
# 需要导入模块: from Acspy.Common import Log [as 别名]
# 或者: from Acspy.Common.Log import getLoggerNames [as 别名]
def testGetLoggerNames(self):
"""NoLoggerCheck getLoggerNames when no loggers requested"""
# When the entire suite is run together, the name from TestContainer is injected.
# This shouldn't happen, but I don't know how to fix it yet.
namelist = Log.getLoggerNames()
self.assertEquals(True, [] == namelist or ['UnitTestContainer'] == namelist)