github.com/anjalikarhana/fabric@v2.1.1+incompatible/orderer/common/cluster/mocks/communicator.go (about)

     1  // Code generated by mockery v1.0.0. DO NOT EDIT.
     2  
     3  package mocks
     4  
     5  import (
     6  	cluster "github.com/hyperledger/fabric/orderer/common/cluster"
     7  	mock "github.com/stretchr/testify/mock"
     8  )
     9  
    10  // Communicator is an autogenerated mock type for the Communicator type
    11  type Communicator struct {
    12  	mock.Mock
    13  }
    14  
    15  // Configure provides a mock function with given fields: channel, members
    16  func (_m *Communicator) Configure(channel string, members []cluster.RemoteNode) {
    17  	_m.Called(channel, members)
    18  }
    19  
    20  // Remote provides a mock function with given fields: channel, id
    21  func (_m *Communicator) Remote(channel string, id uint64) (*cluster.RemoteContext, error) {
    22  	ret := _m.Called(channel, id)
    23  
    24  	var r0 *cluster.RemoteContext
    25  	if rf, ok := ret.Get(0).(func(string, uint64) *cluster.RemoteContext); ok {
    26  		r0 = rf(channel, id)
    27  	} else {
    28  		if ret.Get(0) != nil {
    29  			r0 = ret.Get(0).(*cluster.RemoteContext)
    30  		}
    31  	}
    32  
    33  	var r1 error
    34  	if rf, ok := ret.Get(1).(func(string, uint64) error); ok {
    35  		r1 = rf(channel, id)
    36  	} else {
    37  		r1 = ret.Error(1)
    38  	}
    39  
    40  	return r0, r1
    41  }
    42  
    43  // Shutdown provides a mock function with given fields:
    44  func (_m *Communicator) Shutdown() {
    45  	_m.Called()
    46  }