#NEWLINE# @ mock . patch . object ( host , 'LOG' ) #NEWLINE# def test_connect_auth_cb_exception( self , log_mock ) : #NEWLINE# #INDENT# creds = dict ( authname = 'nova' , password = 'verybadpass' ) #NEWLINE# self . assertRaises ( exception . NovaException , self . host . _connect_auth_cb , creds , False ) #NEWLINE# self . assertEqual ( 0 , len ( log_mock . method_calls ) , 'LOG should not be used in _connect_auth_cb.' )