github.com/metacubex/quic-go@v0.44.1-0.20240520163451-20b689a59136/mock_stream_getter_test.go (about)

     1  // Code generated by MockGen. DO NOT EDIT.
     2  // Source: github.com/metacubex/quic-go (interfaces: StreamGetter)
     3  //
     4  // Generated by this command:
     5  //
     6  //	mockgen -typed -build_flags=-tags=gomock -package quic -self_package github.com/metacubex/quic-go -destination mock_stream_getter_test.go github.com/metacubex/quic-go StreamGetter
     7  //
     8  
     9  // Package quic is a generated GoMock package.
    10  package quic
    11  
    12  import (
    13  	reflect "reflect"
    14  
    15  	protocol "github.com/metacubex/quic-go/internal/protocol"
    16  	gomock "go.uber.org/mock/gomock"
    17  )
    18  
    19  // MockStreamGetter is a mock of StreamGetter interface.
    20  type MockStreamGetter struct {
    21  	ctrl     *gomock.Controller
    22  	recorder *MockStreamGetterMockRecorder
    23  }
    24  
    25  // MockStreamGetterMockRecorder is the mock recorder for MockStreamGetter.
    26  type MockStreamGetterMockRecorder struct {
    27  	mock *MockStreamGetter
    28  }
    29  
    30  // NewMockStreamGetter creates a new mock instance.
    31  func NewMockStreamGetter(ctrl *gomock.Controller) *MockStreamGetter {
    32  	mock := &MockStreamGetter{ctrl: ctrl}
    33  	mock.recorder = &MockStreamGetterMockRecorder{mock}
    34  	return mock
    35  }
    36  
    37  // EXPECT returns an object that allows the caller to indicate expected use.
    38  func (m *MockStreamGetter) EXPECT() *MockStreamGetterMockRecorder {
    39  	return m.recorder
    40  }
    41  
    42  // GetOrOpenReceiveStream mocks base method.
    43  func (m *MockStreamGetter) GetOrOpenReceiveStream(arg0 protocol.StreamID) (receiveStreamI, error) {
    44  	m.ctrl.T.Helper()
    45  	ret := m.ctrl.Call(m, "GetOrOpenReceiveStream", arg0)
    46  	ret0, _ := ret[0].(receiveStreamI)
    47  	ret1, _ := ret[1].(error)
    48  	return ret0, ret1
    49  }
    50  
    51  // GetOrOpenReceiveStream indicates an expected call of GetOrOpenReceiveStream.
    52  func (mr *MockStreamGetterMockRecorder) GetOrOpenReceiveStream(arg0 any) *MockStreamGetterGetOrOpenReceiveStreamCall {
    53  	mr.mock.ctrl.T.Helper()
    54  	call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetOrOpenReceiveStream", reflect.TypeOf((*MockStreamGetter)(nil).GetOrOpenReceiveStream), arg0)
    55  	return &MockStreamGetterGetOrOpenReceiveStreamCall{Call: call}
    56  }
    57  
    58  // MockStreamGetterGetOrOpenReceiveStreamCall wrap *gomock.Call
    59  type MockStreamGetterGetOrOpenReceiveStreamCall struct {
    60  	*gomock.Call
    61  }
    62  
    63  // Return rewrite *gomock.Call.Return
    64  func (c *MockStreamGetterGetOrOpenReceiveStreamCall) Return(arg0 receiveStreamI, arg1 error) *MockStreamGetterGetOrOpenReceiveStreamCall {
    65  	c.Call = c.Call.Return(arg0, arg1)
    66  	return c
    67  }
    68  
    69  // Do rewrite *gomock.Call.Do
    70  func (c *MockStreamGetterGetOrOpenReceiveStreamCall) Do(f func(protocol.StreamID) (receiveStreamI, error)) *MockStreamGetterGetOrOpenReceiveStreamCall {
    71  	c.Call = c.Call.Do(f)
    72  	return c
    73  }
    74  
    75  // DoAndReturn rewrite *gomock.Call.DoAndReturn
    76  func (c *MockStreamGetterGetOrOpenReceiveStreamCall) DoAndReturn(f func(protocol.StreamID) (receiveStreamI, error)) *MockStreamGetterGetOrOpenReceiveStreamCall {
    77  	c.Call = c.Call.DoAndReturn(f)
    78  	return c
    79  }
    80  
    81  // GetOrOpenSendStream mocks base method.
    82  func (m *MockStreamGetter) GetOrOpenSendStream(arg0 protocol.StreamID) (sendStreamI, error) {
    83  	m.ctrl.T.Helper()
    84  	ret := m.ctrl.Call(m, "GetOrOpenSendStream", arg0)
    85  	ret0, _ := ret[0].(sendStreamI)
    86  	ret1, _ := ret[1].(error)
    87  	return ret0, ret1
    88  }
    89  
    90  // GetOrOpenSendStream indicates an expected call of GetOrOpenSendStream.
    91  func (mr *MockStreamGetterMockRecorder) GetOrOpenSendStream(arg0 any) *MockStreamGetterGetOrOpenSendStreamCall {
    92  	mr.mock.ctrl.T.Helper()
    93  	call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetOrOpenSendStream", reflect.TypeOf((*MockStreamGetter)(nil).GetOrOpenSendStream), arg0)
    94  	return &MockStreamGetterGetOrOpenSendStreamCall{Call: call}
    95  }
    96  
    97  // MockStreamGetterGetOrOpenSendStreamCall wrap *gomock.Call
    98  type MockStreamGetterGetOrOpenSendStreamCall struct {
    99  	*gomock.Call
   100  }
   101  
   102  // Return rewrite *gomock.Call.Return
   103  func (c *MockStreamGetterGetOrOpenSendStreamCall) Return(arg0 sendStreamI, arg1 error) *MockStreamGetterGetOrOpenSendStreamCall {
   104  	c.Call = c.Call.Return(arg0, arg1)
   105  	return c
   106  }
   107  
   108  // Do rewrite *gomock.Call.Do
   109  func (c *MockStreamGetterGetOrOpenSendStreamCall) Do(f func(protocol.StreamID) (sendStreamI, error)) *MockStreamGetterGetOrOpenSendStreamCall {
   110  	c.Call = c.Call.Do(f)
   111  	return c
   112  }
   113  
   114  // DoAndReturn rewrite *gomock.Call.DoAndReturn
   115  func (c *MockStreamGetterGetOrOpenSendStreamCall) DoAndReturn(f func(protocol.StreamID) (sendStreamI, error)) *MockStreamGetterGetOrOpenSendStreamCall {
   116  	c.Call = c.Call.DoAndReturn(f)
   117  	return c
   118  }