#NEWLINE# def test_malformed_reply( self ) : #NEWLINE# #INDENT# GoGridMockHttp . type = 'FAIL' #NEWLINE# try : #NEWLINE# #INDENT# self . driver . list_images ( ) #NEWLINE# #UNINDENT# except LibcloudError : #NEWLINE# #INDENT# e = sys . exc_info ( ) [ 1 ] #NEWLINE# self . assertTrue ( isinstance ( self , LibcloudError ) ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# self . fail ( 'test should have thrown' )