本文整理汇总了Python中Utils.Logger.logfileName方法的典型用法代码示例。如果您正苦于以下问题:Python Logger.logfileName方法的具体用法?Python Logger.logfileName怎么用?Python Logger.logfileName使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Utils.Logger
的用法示例。
在下文中一共展示了Logger.logfileName方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: Logger
# 需要导入模块: from Utils import Logger [as 别名]
# 或者: from Utils.Logger import logfileName [as 别名]
return metadata
###################################
# Module tests:
###################################
if __name__ == '__main__':
darInput = string.split(
"""
SimpleValue1 = abra-kadabra
SimpleValue2 = 123
PathToFile = /home/natasha/.signature
PathToDir = /scratch/natasha/www
SEALKEEPMODULES = true
PATH = /afs/fnal.gov/files/code/cms/l/Releases/ORCA/ORCA811/bin/Linux__2.4:/afs/fnal.gov/exp/cms/l/Releases/COBRA/COBRA781/bin/Linux__2.4:/afs/fnal.gov/exp/cms/l/Releases/IGNOMINY/IGNOMINY180/bin/Linux__2.4
prependPath LD_LIBRARY_PATH /home/natasha/lib allkhaf/asl
postpendPath LD_LIBRARY_PATH blabla
ignore PATH""", "\n")
tmpDir = "/tmp/natashaTestMetadata"
os.mkdir(tmpDir)
logger = Logger(tmpDir + '/logger')
logger('started test')
logger('created request')
metadata = Metadata()
metadata.setLogFile(logger.logfileName())
#print metadata.userInfo()
logger('finished Metadata unit-test')
print metadata
metadata.saveMetadata(tmpDir + '/metadataFile')