github.com/MerlinKodo/quic-go@v0.39.2/mock_stream_internal_test.go (about)

     1  // Code generated by MockGen. DO NOT EDIT.
     2  // Source: github.com/MerlinKodo/quic-go (interfaces: StreamI)
     3  //
     4  // Generated by this command:
     5  //
     6  //	mockgen -build_flags=-tags=gomock -package quic -self_package github.com/MerlinKodo/quic-go -destination mock_stream_internal_test.go github.com/MerlinKodo/quic-go StreamI
     7  //
     8  // Package quic is a generated GoMock package.
     9  package quic
    10  
    11  import (
    12  	context "context"
    13  	reflect "reflect"
    14  	time "time"
    15  
    16  	ackhandler "github.com/MerlinKodo/quic-go/internal/ackhandler"
    17  	protocol "github.com/MerlinKodo/quic-go/internal/protocol"
    18  	qerr "github.com/MerlinKodo/quic-go/internal/qerr"
    19  	wire "github.com/MerlinKodo/quic-go/internal/wire"
    20  	gomock "go.uber.org/mock/gomock"
    21  )
    22  
    23  // MockStreamI is a mock of StreamI interface.
    24  type MockStreamI struct {
    25  	ctrl     *gomock.Controller
    26  	recorder *MockStreamIMockRecorder
    27  }
    28  
    29  // MockStreamIMockRecorder is the mock recorder for MockStreamI.
    30  type MockStreamIMockRecorder struct {
    31  	mock *MockStreamI
    32  }
    33  
    34  // NewMockStreamI creates a new mock instance.
    35  func NewMockStreamI(ctrl *gomock.Controller) *MockStreamI {
    36  	mock := &MockStreamI{ctrl: ctrl}
    37  	mock.recorder = &MockStreamIMockRecorder{mock}
    38  	return mock
    39  }
    40  
    41  // EXPECT returns an object that allows the caller to indicate expected use.
    42  func (m *MockStreamI) EXPECT() *MockStreamIMockRecorder {
    43  	return m.recorder
    44  }
    45  
    46  // CancelRead mocks base method.
    47  func (m *MockStreamI) CancelRead(arg0 qerr.StreamErrorCode) {
    48  	m.ctrl.T.Helper()
    49  	m.ctrl.Call(m, "CancelRead", arg0)
    50  }
    51  
    52  // CancelRead indicates an expected call of CancelRead.
    53  func (mr *MockStreamIMockRecorder) CancelRead(arg0 any) *gomock.Call {
    54  	mr.mock.ctrl.T.Helper()
    55  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CancelRead", reflect.TypeOf((*MockStreamI)(nil).CancelRead), arg0)
    56  }
    57  
    58  // CancelWrite mocks base method.
    59  func (m *MockStreamI) CancelWrite(arg0 qerr.StreamErrorCode) {
    60  	m.ctrl.T.Helper()
    61  	m.ctrl.Call(m, "CancelWrite", arg0)
    62  }
    63  
    64  // CancelWrite indicates an expected call of CancelWrite.
    65  func (mr *MockStreamIMockRecorder) CancelWrite(arg0 any) *gomock.Call {
    66  	mr.mock.ctrl.T.Helper()
    67  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CancelWrite", reflect.TypeOf((*MockStreamI)(nil).CancelWrite), arg0)
    68  }
    69  
    70  // Close mocks base method.
    71  func (m *MockStreamI) Close() error {
    72  	m.ctrl.T.Helper()
    73  	ret := m.ctrl.Call(m, "Close")
    74  	ret0, _ := ret[0].(error)
    75  	return ret0
    76  }
    77  
    78  // Close indicates an expected call of Close.
    79  func (mr *MockStreamIMockRecorder) Close() *gomock.Call {
    80  	mr.mock.ctrl.T.Helper()
    81  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Close", reflect.TypeOf((*MockStreamI)(nil).Close))
    82  }
    83  
    84  // Context mocks base method.
    85  func (m *MockStreamI) Context() context.Context {
    86  	m.ctrl.T.Helper()
    87  	ret := m.ctrl.Call(m, "Context")
    88  	ret0, _ := ret[0].(context.Context)
    89  	return ret0
    90  }
    91  
    92  // Context indicates an expected call of Context.
    93  func (mr *MockStreamIMockRecorder) Context() *gomock.Call {
    94  	mr.mock.ctrl.T.Helper()
    95  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Context", reflect.TypeOf((*MockStreamI)(nil).Context))
    96  }
    97  
    98  // Read mocks base method.
    99  func (m *MockStreamI) Read(arg0 []byte) (int, error) {
   100  	m.ctrl.T.Helper()
   101  	ret := m.ctrl.Call(m, "Read", arg0)
   102  	ret0, _ := ret[0].(int)
   103  	ret1, _ := ret[1].(error)
   104  	return ret0, ret1
   105  }
   106  
   107  // Read indicates an expected call of Read.
   108  func (mr *MockStreamIMockRecorder) Read(arg0 any) *gomock.Call {
   109  	mr.mock.ctrl.T.Helper()
   110  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Read", reflect.TypeOf((*MockStreamI)(nil).Read), arg0)
   111  }
   112  
   113  // SetDeadline mocks base method.
   114  func (m *MockStreamI) SetDeadline(arg0 time.Time) error {
   115  	m.ctrl.T.Helper()
   116  	ret := m.ctrl.Call(m, "SetDeadline", arg0)
   117  	ret0, _ := ret[0].(error)
   118  	return ret0
   119  }
   120  
   121  // SetDeadline indicates an expected call of SetDeadline.
   122  func (mr *MockStreamIMockRecorder) SetDeadline(arg0 any) *gomock.Call {
   123  	mr.mock.ctrl.T.Helper()
   124  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SetDeadline", reflect.TypeOf((*MockStreamI)(nil).SetDeadline), arg0)
   125  }
   126  
   127  // SetReadDeadline mocks base method.
   128  func (m *MockStreamI) SetReadDeadline(arg0 time.Time) error {
   129  	m.ctrl.T.Helper()
   130  	ret := m.ctrl.Call(m, "SetReadDeadline", arg0)
   131  	ret0, _ := ret[0].(error)
   132  	return ret0
   133  }
   134  
   135  // SetReadDeadline indicates an expected call of SetReadDeadline.
   136  func (mr *MockStreamIMockRecorder) SetReadDeadline(arg0 any) *gomock.Call {
   137  	mr.mock.ctrl.T.Helper()
   138  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SetReadDeadline", reflect.TypeOf((*MockStreamI)(nil).SetReadDeadline), arg0)
   139  }
   140  
   141  // SetWriteDeadline mocks base method.
   142  func (m *MockStreamI) SetWriteDeadline(arg0 time.Time) error {
   143  	m.ctrl.T.Helper()
   144  	ret := m.ctrl.Call(m, "SetWriteDeadline", arg0)
   145  	ret0, _ := ret[0].(error)
   146  	return ret0
   147  }
   148  
   149  // SetWriteDeadline indicates an expected call of SetWriteDeadline.
   150  func (mr *MockStreamIMockRecorder) SetWriteDeadline(arg0 any) *gomock.Call {
   151  	mr.mock.ctrl.T.Helper()
   152  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SetWriteDeadline", reflect.TypeOf((*MockStreamI)(nil).SetWriteDeadline), arg0)
   153  }
   154  
   155  // StreamID mocks base method.
   156  func (m *MockStreamI) StreamID() protocol.StreamID {
   157  	m.ctrl.T.Helper()
   158  	ret := m.ctrl.Call(m, "StreamID")
   159  	ret0, _ := ret[0].(protocol.StreamID)
   160  	return ret0
   161  }
   162  
   163  // StreamID indicates an expected call of StreamID.
   164  func (mr *MockStreamIMockRecorder) StreamID() *gomock.Call {
   165  	mr.mock.ctrl.T.Helper()
   166  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "StreamID", reflect.TypeOf((*MockStreamI)(nil).StreamID))
   167  }
   168  
   169  // Write mocks base method.
   170  func (m *MockStreamI) Write(arg0 []byte) (int, error) {
   171  	m.ctrl.T.Helper()
   172  	ret := m.ctrl.Call(m, "Write", arg0)
   173  	ret0, _ := ret[0].(int)
   174  	ret1, _ := ret[1].(error)
   175  	return ret0, ret1
   176  }
   177  
   178  // Write indicates an expected call of Write.
   179  func (mr *MockStreamIMockRecorder) Write(arg0 any) *gomock.Call {
   180  	mr.mock.ctrl.T.Helper()
   181  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Write", reflect.TypeOf((*MockStreamI)(nil).Write), arg0)
   182  }
   183  
   184  // closeForShutdown mocks base method.
   185  func (m *MockStreamI) closeForShutdown(arg0 error) {
   186  	m.ctrl.T.Helper()
   187  	m.ctrl.Call(m, "closeForShutdown", arg0)
   188  }
   189  
   190  // closeForShutdown indicates an expected call of closeForShutdown.
   191  func (mr *MockStreamIMockRecorder) closeForShutdown(arg0 any) *gomock.Call {
   192  	mr.mock.ctrl.T.Helper()
   193  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "closeForShutdown", reflect.TypeOf((*MockStreamI)(nil).closeForShutdown), arg0)
   194  }
   195  
   196  // getWindowUpdate mocks base method.
   197  func (m *MockStreamI) getWindowUpdate() protocol.ByteCount {
   198  	m.ctrl.T.Helper()
   199  	ret := m.ctrl.Call(m, "getWindowUpdate")
   200  	ret0, _ := ret[0].(protocol.ByteCount)
   201  	return ret0
   202  }
   203  
   204  // getWindowUpdate indicates an expected call of getWindowUpdate.
   205  func (mr *MockStreamIMockRecorder) getWindowUpdate() *gomock.Call {
   206  	mr.mock.ctrl.T.Helper()
   207  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "getWindowUpdate", reflect.TypeOf((*MockStreamI)(nil).getWindowUpdate))
   208  }
   209  
   210  // handleResetStreamFrame mocks base method.
   211  func (m *MockStreamI) handleResetStreamFrame(arg0 *wire.ResetStreamFrame) error {
   212  	m.ctrl.T.Helper()
   213  	ret := m.ctrl.Call(m, "handleResetStreamFrame", arg0)
   214  	ret0, _ := ret[0].(error)
   215  	return ret0
   216  }
   217  
   218  // handleResetStreamFrame indicates an expected call of handleResetStreamFrame.
   219  func (mr *MockStreamIMockRecorder) handleResetStreamFrame(arg0 any) *gomock.Call {
   220  	mr.mock.ctrl.T.Helper()
   221  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "handleResetStreamFrame", reflect.TypeOf((*MockStreamI)(nil).handleResetStreamFrame), arg0)
   222  }
   223  
   224  // handleStopSendingFrame mocks base method.
   225  func (m *MockStreamI) handleStopSendingFrame(arg0 *wire.StopSendingFrame) {
   226  	m.ctrl.T.Helper()
   227  	m.ctrl.Call(m, "handleStopSendingFrame", arg0)
   228  }
   229  
   230  // handleStopSendingFrame indicates an expected call of handleStopSendingFrame.
   231  func (mr *MockStreamIMockRecorder) handleStopSendingFrame(arg0 any) *gomock.Call {
   232  	mr.mock.ctrl.T.Helper()
   233  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "handleStopSendingFrame", reflect.TypeOf((*MockStreamI)(nil).handleStopSendingFrame), arg0)
   234  }
   235  
   236  // handleStreamFrame mocks base method.
   237  func (m *MockStreamI) handleStreamFrame(arg0 *wire.StreamFrame) error {
   238  	m.ctrl.T.Helper()
   239  	ret := m.ctrl.Call(m, "handleStreamFrame", arg0)
   240  	ret0, _ := ret[0].(error)
   241  	return ret0
   242  }
   243  
   244  // handleStreamFrame indicates an expected call of handleStreamFrame.
   245  func (mr *MockStreamIMockRecorder) handleStreamFrame(arg0 any) *gomock.Call {
   246  	mr.mock.ctrl.T.Helper()
   247  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "handleStreamFrame", reflect.TypeOf((*MockStreamI)(nil).handleStreamFrame), arg0)
   248  }
   249  
   250  // hasData mocks base method.
   251  func (m *MockStreamI) hasData() bool {
   252  	m.ctrl.T.Helper()
   253  	ret := m.ctrl.Call(m, "hasData")
   254  	ret0, _ := ret[0].(bool)
   255  	return ret0
   256  }
   257  
   258  // hasData indicates an expected call of hasData.
   259  func (mr *MockStreamIMockRecorder) hasData() *gomock.Call {
   260  	mr.mock.ctrl.T.Helper()
   261  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "hasData", reflect.TypeOf((*MockStreamI)(nil).hasData))
   262  }
   263  
   264  // popStreamFrame mocks base method.
   265  func (m *MockStreamI) popStreamFrame(arg0 protocol.ByteCount, arg1 protocol.VersionNumber) (ackhandler.StreamFrame, bool, bool) {
   266  	m.ctrl.T.Helper()
   267  	ret := m.ctrl.Call(m, "popStreamFrame", arg0, arg1)
   268  	ret0, _ := ret[0].(ackhandler.StreamFrame)
   269  	ret1, _ := ret[1].(bool)
   270  	ret2, _ := ret[2].(bool)
   271  	return ret0, ret1, ret2
   272  }
   273  
   274  // popStreamFrame indicates an expected call of popStreamFrame.
   275  func (mr *MockStreamIMockRecorder) popStreamFrame(arg0, arg1 any) *gomock.Call {
   276  	mr.mock.ctrl.T.Helper()
   277  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "popStreamFrame", reflect.TypeOf((*MockStreamI)(nil).popStreamFrame), arg0, arg1)
   278  }
   279  
   280  // updateSendWindow mocks base method.
   281  func (m *MockStreamI) updateSendWindow(arg0 protocol.ByteCount) {
   282  	m.ctrl.T.Helper()
   283  	m.ctrl.Call(m, "updateSendWindow", arg0)
   284  }
   285  
   286  // updateSendWindow indicates an expected call of updateSendWindow.
   287  func (mr *MockStreamIMockRecorder) updateSendWindow(arg0 any) *gomock.Call {
   288  	mr.mock.ctrl.T.Helper()
   289  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "updateSendWindow", reflect.TypeOf((*MockStreamI)(nil).updateSendWindow), arg0)
   290  }