#NEWLINE# def test_format( self , record ) : #NEWLINE# #INDENT# fmt = pyfluent . logging . FluentFormatter ( ) #NEWLINE# expected = { #NEWLINE# #INDENT# 'message' : 'message 1' , #NEWLINE# 'hostname' : self . hostname , #NEWLINE# 'filename' : 'source.py' , #NEWLINE# 'name' : 'root' , #NEWLINE# 'levelname' : 'info' , #NEWLINE# 'lineno' : '10' , #NEWLINE# 'funcName' : 'func_name' , #NEWLINE# 'exc_text' : None , #NEWLINE# 'module' : 'source' , #NEWLINE# 'pathname' : '/path/to/source.py' , #NEWLINE# 'process' : os . getpid ( ) , #NEWLINE# 'processName' : 'MainProcess' , #NEWLINE# 'threadName' : 'MainThread' , #NEWLINE# #UNINDENT# } #NEWLINE# if ( sys . version_info [ : 3 ] >= ( 3 , 2 , 0 ) ) : #NEWLINE# #INDENT# expected [ 'stack_info' ] = None #NEWLINE# #UNINDENT# if ( ( sys . version_info [ : 3 ] < ( 2 , 6 , 0 ) ) or ( sys . version_info [ : 2 ] == ( 3 , 0 ) ) ) : #NEWLINE# #INDENT# del expected [ 'processName' ] #NEWLINE# #UNINDENT# assert ( fmt . format ( record ) == self )