#NEWLINE# @ patch ( 'pyon.net.endpoint.RPCRequestEndpointUnit._build_conv_id' , Mock ( return_value = sentinel . conv_id ) ) #NEWLINE# def test_endpoint_send( self ) : #NEWLINE# #INDENT# e = RPCRequestEndpointUnit ( interceptors = { #NEWLINE# #INDENT# #NEWLINE# #UNINDENT# } ) #NEWLINE# ch = self . _setup_mock_channel ( ) #NEWLINE# e . attach_channel ( ch ) #NEWLINE# ( ret , heads ) = e . send ( 'rpc call' ) #NEWLINE# self . assertEquals ( e , 'bidirmsg' ) #NEWLINE# e . close ( )