Documentation ¶
Overview ¶
Package mocks is a generated GoMock package.
Package mocks is a generated GoMock package.
Index ¶
- type MockPeerPacketStream
- type MockPeerPacketStreamMockRecorder
- type MockSchedulerClient
- func (m *MockSchedulerClient) Close() error
- func (m *MockSchedulerClient) EXPECT() *MockSchedulerClientMockRecorder
- func (m *MockSchedulerClient) LeaveTask(arg0 context.Context, arg1 *scheduler.PeerTarget, arg2 ...grpc.CallOption) error
- func (m *MockSchedulerClient) RegisterPeerTask(arg0 context.Context, arg1 *scheduler.PeerTaskRequest, arg2 ...grpc.CallOption) (*scheduler.RegisterResult, error)
- func (m *MockSchedulerClient) ReportPeerResult(arg0 context.Context, arg1 *scheduler.PeerResult, arg2 ...grpc.CallOption) error
- func (m *MockSchedulerClient) ReportPieceResult(arg0 context.Context, arg1 string, arg2 *scheduler.PeerTaskRequest, ...) (client.PeerPacketStream, error)
- func (m *MockSchedulerClient) UpdateState(addrs []dfnet.NetAddr)
- type MockSchedulerClientMockRecorder
- func (mr *MockSchedulerClientMockRecorder) Close() *gomock.Call
- func (mr *MockSchedulerClientMockRecorder) LeaveTask(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call
- func (mr *MockSchedulerClientMockRecorder) RegisterPeerTask(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call
- func (mr *MockSchedulerClientMockRecorder) ReportPeerResult(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call
- func (mr *MockSchedulerClientMockRecorder) ReportPieceResult(arg0, arg1, arg2 interface{}, arg3 ...interface{}) *gomock.Call
- func (mr *MockSchedulerClientMockRecorder) UpdateState(addrs interface{}) *gomock.Call
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MockPeerPacketStream ¶
type MockPeerPacketStream struct {
// contains filtered or unexported fields
}
MockPeerPacketStream is a mock of PeerPacketStream interface.
func NewMockPeerPacketStream ¶
func NewMockPeerPacketStream(ctrl *gomock.Controller) *MockPeerPacketStream
NewMockPeerPacketStream creates a new mock instance.
func (*MockPeerPacketStream) EXPECT ¶
func (m *MockPeerPacketStream) EXPECT() *MockPeerPacketStreamMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
func (*MockPeerPacketStream) Recv ¶
func (m *MockPeerPacketStream) Recv() (*scheduler.PeerPacket, error)
Recv mocks base method.
func (*MockPeerPacketStream) Send ¶
func (m *MockPeerPacketStream) Send(pr *scheduler.PieceResult) error
Send mocks base method.
type MockPeerPacketStreamMockRecorder ¶
type MockPeerPacketStreamMockRecorder struct {
// contains filtered or unexported fields
}
MockPeerPacketStreamMockRecorder is the mock recorder for MockPeerPacketStream.
func (*MockPeerPacketStreamMockRecorder) Recv ¶
func (mr *MockPeerPacketStreamMockRecorder) Recv() *gomock.Call
Recv indicates an expected call of Recv.
func (*MockPeerPacketStreamMockRecorder) Send ¶
func (mr *MockPeerPacketStreamMockRecorder) Send(pr interface{}) *gomock.Call
Send indicates an expected call of Send.
type MockSchedulerClient ¶
type MockSchedulerClient struct {
// contains filtered or unexported fields
}
MockSchedulerClient is a mock of SchedulerClient interface.
func NewMockSchedulerClient ¶
func NewMockSchedulerClient(ctrl *gomock.Controller) *MockSchedulerClient
NewMockSchedulerClient creates a new mock instance.
func (*MockSchedulerClient) Close ¶
func (m *MockSchedulerClient) Close() error
Close mocks base method.
func (*MockSchedulerClient) EXPECT ¶
func (m *MockSchedulerClient) EXPECT() *MockSchedulerClientMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
func (*MockSchedulerClient) LeaveTask ¶
func (m *MockSchedulerClient) LeaveTask(arg0 context.Context, arg1 *scheduler.PeerTarget, arg2 ...grpc.CallOption) error
LeaveTask mocks base method.
func (*MockSchedulerClient) RegisterPeerTask ¶
func (m *MockSchedulerClient) RegisterPeerTask(arg0 context.Context, arg1 *scheduler.PeerTaskRequest, arg2 ...grpc.CallOption) (*scheduler.RegisterResult, error)
RegisterPeerTask mocks base method.
func (*MockSchedulerClient) ReportPeerResult ¶
func (m *MockSchedulerClient) ReportPeerResult(arg0 context.Context, arg1 *scheduler.PeerResult, arg2 ...grpc.CallOption) error
ReportPeerResult mocks base method.
func (*MockSchedulerClient) ReportPieceResult ¶
func (m *MockSchedulerClient) ReportPieceResult(arg0 context.Context, arg1 string, arg2 *scheduler.PeerTaskRequest, arg3 ...grpc.CallOption) (client.PeerPacketStream, error)
ReportPieceResult mocks base method.
func (*MockSchedulerClient) UpdateState ¶
func (m *MockSchedulerClient) UpdateState(addrs []dfnet.NetAddr)
UpdateState mocks base method.
type MockSchedulerClientMockRecorder ¶
type MockSchedulerClientMockRecorder struct {
// contains filtered or unexported fields
}
MockSchedulerClientMockRecorder is the mock recorder for MockSchedulerClient.
func (*MockSchedulerClientMockRecorder) Close ¶
func (mr *MockSchedulerClientMockRecorder) Close() *gomock.Call
Close indicates an expected call of Close.
func (*MockSchedulerClientMockRecorder) LeaveTask ¶
func (mr *MockSchedulerClientMockRecorder) LeaveTask(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call
LeaveTask indicates an expected call of LeaveTask.
func (*MockSchedulerClientMockRecorder) RegisterPeerTask ¶
func (mr *MockSchedulerClientMockRecorder) RegisterPeerTask(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call
RegisterPeerTask indicates an expected call of RegisterPeerTask.
func (*MockSchedulerClientMockRecorder) ReportPeerResult ¶
func (mr *MockSchedulerClientMockRecorder) ReportPeerResult(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call
ReportPeerResult indicates an expected call of ReportPeerResult.
func (*MockSchedulerClientMockRecorder) ReportPieceResult ¶
func (mr *MockSchedulerClientMockRecorder) ReportPieceResult(arg0, arg1, arg2 interface{}, arg3 ...interface{}) *gomock.Call
ReportPieceResult indicates an expected call of ReportPieceResult.
func (*MockSchedulerClientMockRecorder) UpdateState ¶
func (mr *MockSchedulerClientMockRecorder) UpdateState(addrs interface{}) *gomock.Call
UpdateState indicates an expected call of UpdateState.