#NEWLINE# def log( self , level , codes , msg , **args ) : #NEWLINE# #INDENT# 'Same as error(), but level passed in as argument\n        ' #NEWLINE# logger = self . logger #NEWLINE# ( messageCode , logArgs , extras ) = self . logArguments ( codes , msg , args ) #NEWLINE# if ( messageCode == 'asrtNoLog' ) : #NEWLINE# #INDENT# self . errors . append ( args [ 'assertionResults' ] ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# if ( messageCode and ( ( not logger . messageCodeFilter ) or logger . messageCodeFilter . match ( messageCode ) ) and ( ( not logger . messageLevelFilter ) or logger . messageLevelFilter . match ( level . lower ( ) ) ) ) : #NEWLINE# #INDENT# numericLevel = logging . _checkLevel ( level ) #NEWLINE# self . logCount [ numericLevel ] = ( self . logCount . get ( numericLevel , 0 ) + 1 ) #NEWLINE# if ( numericLevel >= self . errorCaptureLevel ) : #NEWLINE# #INDENT# self . errors . append ( messageCode ) #NEWLINE# #UNINDENT# '@messageCatalog=[]' #NEWLINE# logger . log ( numericLevel , * logArgs , exc_info = args . get ( 'exc_info' ) , extra = extras )