#NEWLINE# def setUp( self ) : #NEWLINE# #INDENT# super ( VmdkReadHandleTest , self ) . setUp ( ) #NEWLINE# self . _resp = mock . Mock ( ) #NEWLINE# self . _resp . read . return_value = 'fake-data' #NEWLINE# self . _conn = mock . Mock ( ) #NEWLINE# self . _conn . getresponse . return_value = self . _resp #NEWLINE# patcher = mock . patch ( 'urllib3.connection.HTTPConnection' ) #NEWLINE# self . addCleanup ( patcher . stop ) #NEWLINE# HTTPConnectionMock = patcher . start ( ) #NEWLINE# HTTPConnectionMock . return_value = HTTPConnectionMock . _conn