#NEWLINE# def test( self ) : #NEWLINE# #INDENT# def handle_response( resp ) : #NEWLINE# #INDENT# self . assertIsNone ( resp . error ) #NEWLINE# self . ioloop . stop ( ) #NEWLINE# #UNINDENT# tornado . httpclient . AsyncHTTPClient . configure ( 'tornado.curl_httpclient.CurlAsyncHTTPClient' ) #NEWLINE# client = tornado . httpclient . AsyncHTTPClient ( ) #NEWLINE# req = tornado . httpclient . HTTPRequest ( 'http://xiaorui.cc/' , proxy_host = '127.0.0.1' , proxy_port = 8889 ) #NEWLINE# client . fetch ( self , handle_response ) #NEWLINE# self . ioloop . start ( )