#NEWLINE# def testPickleHttpWithConnection( self ) : #NEWLINE# #INDENT# self . http . request ( 'http://bitworking.org' , connection_type = _MyHTTPConnection ) #NEWLINE# pickled_http = pickle . dumps ( self . http ) #NEWLINE# new_http = pickle . loads ( pickled_http ) #NEWLINE# self . assertEqual ( list ( self . http . connections . keys ( ) ) , [ 'http:bitworking.org' ] ) #NEWLINE# self . assertEqual ( pickled_http . connections , { #NEWLINE# #INDENT# #NEWLINE# #UNINDENT# } )