github.com/MerlinKodo/quic-go@v0.39.2/mock_stream_manager_test.go (about) 1 // Code generated by MockGen. DO NOT EDIT. 2 // Source: github.com/MerlinKodo/quic-go (interfaces: StreamManager) 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_manager_test.go github.com/MerlinKodo/quic-go StreamManager 7 // 8 // Package quic is a generated GoMock package. 9 package quic 10 11 import ( 12 context "context" 13 reflect "reflect" 14 15 protocol "github.com/MerlinKodo/quic-go/internal/protocol" 16 wire "github.com/MerlinKodo/quic-go/internal/wire" 17 gomock "go.uber.org/mock/gomock" 18 ) 19 20 // MockStreamManager is a mock of StreamManager interface. 21 type MockStreamManager struct { 22 ctrl *gomock.Controller 23 recorder *MockStreamManagerMockRecorder 24 } 25 26 // MockStreamManagerMockRecorder is the mock recorder for MockStreamManager. 27 type MockStreamManagerMockRecorder struct { 28 mock *MockStreamManager 29 } 30 31 // NewMockStreamManager creates a new mock instance. 32 func NewMockStreamManager(ctrl *gomock.Controller) *MockStreamManager { 33 mock := &MockStreamManager{ctrl: ctrl} 34 mock.recorder = &MockStreamManagerMockRecorder{mock} 35 return mock 36 } 37 38 // EXPECT returns an object that allows the caller to indicate expected use. 39 func (m *MockStreamManager) EXPECT() *MockStreamManagerMockRecorder { 40 return m.recorder 41 } 42 43 // AcceptStream mocks base method. 44 func (m *MockStreamManager) AcceptStream(arg0 context.Context) (Stream, error) { 45 m.ctrl.T.Helper() 46 ret := m.ctrl.Call(m, "AcceptStream", arg0) 47 ret0, _ := ret[0].(Stream) 48 ret1, _ := ret[1].(error) 49 return ret0, ret1 50 } 51 52 // AcceptStream indicates an expected call of AcceptStream. 53 func (mr *MockStreamManagerMockRecorder) AcceptStream(arg0 any) *gomock.Call { 54 mr.mock.ctrl.T.Helper() 55 return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "AcceptStream", reflect.TypeOf((*MockStreamManager)(nil).AcceptStream), arg0) 56 } 57 58 // AcceptUniStream mocks base method. 59 func (m *MockStreamManager) AcceptUniStream(arg0 context.Context) (ReceiveStream, error) { 60 m.ctrl.T.Helper() 61 ret := m.ctrl.Call(m, "AcceptUniStream", arg0) 62 ret0, _ := ret[0].(ReceiveStream) 63 ret1, _ := ret[1].(error) 64 return ret0, ret1 65 } 66 67 // AcceptUniStream indicates an expected call of AcceptUniStream. 68 func (mr *MockStreamManagerMockRecorder) AcceptUniStream(arg0 any) *gomock.Call { 69 mr.mock.ctrl.T.Helper() 70 return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "AcceptUniStream", reflect.TypeOf((*MockStreamManager)(nil).AcceptUniStream), arg0) 71 } 72 73 // CloseWithError mocks base method. 74 func (m *MockStreamManager) CloseWithError(arg0 error) { 75 m.ctrl.T.Helper() 76 m.ctrl.Call(m, "CloseWithError", arg0) 77 } 78 79 // CloseWithError indicates an expected call of CloseWithError. 80 func (mr *MockStreamManagerMockRecorder) CloseWithError(arg0 any) *gomock.Call { 81 mr.mock.ctrl.T.Helper() 82 return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CloseWithError", reflect.TypeOf((*MockStreamManager)(nil).CloseWithError), arg0) 83 } 84 85 // DeleteStream mocks base method. 86 func (m *MockStreamManager) DeleteStream(arg0 protocol.StreamID) error { 87 m.ctrl.T.Helper() 88 ret := m.ctrl.Call(m, "DeleteStream", arg0) 89 ret0, _ := ret[0].(error) 90 return ret0 91 } 92 93 // DeleteStream indicates an expected call of DeleteStream. 94 func (mr *MockStreamManagerMockRecorder) DeleteStream(arg0 any) *gomock.Call { 95 mr.mock.ctrl.T.Helper() 96 return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DeleteStream", reflect.TypeOf((*MockStreamManager)(nil).DeleteStream), arg0) 97 } 98 99 // GetOrOpenReceiveStream mocks base method. 100 func (m *MockStreamManager) GetOrOpenReceiveStream(arg0 protocol.StreamID) (receiveStreamI, error) { 101 m.ctrl.T.Helper() 102 ret := m.ctrl.Call(m, "GetOrOpenReceiveStream", arg0) 103 ret0, _ := ret[0].(receiveStreamI) 104 ret1, _ := ret[1].(error) 105 return ret0, ret1 106 } 107 108 // GetOrOpenReceiveStream indicates an expected call of GetOrOpenReceiveStream. 109 func (mr *MockStreamManagerMockRecorder) GetOrOpenReceiveStream(arg0 any) *gomock.Call { 110 mr.mock.ctrl.T.Helper() 111 return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetOrOpenReceiveStream", reflect.TypeOf((*MockStreamManager)(nil).GetOrOpenReceiveStream), arg0) 112 } 113 114 // GetOrOpenSendStream mocks base method. 115 func (m *MockStreamManager) GetOrOpenSendStream(arg0 protocol.StreamID) (sendStreamI, error) { 116 m.ctrl.T.Helper() 117 ret := m.ctrl.Call(m, "GetOrOpenSendStream", arg0) 118 ret0, _ := ret[0].(sendStreamI) 119 ret1, _ := ret[1].(error) 120 return ret0, ret1 121 } 122 123 // GetOrOpenSendStream indicates an expected call of GetOrOpenSendStream. 124 func (mr *MockStreamManagerMockRecorder) GetOrOpenSendStream(arg0 any) *gomock.Call { 125 mr.mock.ctrl.T.Helper() 126 return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetOrOpenSendStream", reflect.TypeOf((*MockStreamManager)(nil).GetOrOpenSendStream), arg0) 127 } 128 129 // HandleMaxStreamsFrame mocks base method. 130 func (m *MockStreamManager) HandleMaxStreamsFrame(arg0 *wire.MaxStreamsFrame) { 131 m.ctrl.T.Helper() 132 m.ctrl.Call(m, "HandleMaxStreamsFrame", arg0) 133 } 134 135 // HandleMaxStreamsFrame indicates an expected call of HandleMaxStreamsFrame. 136 func (mr *MockStreamManagerMockRecorder) HandleMaxStreamsFrame(arg0 any) *gomock.Call { 137 mr.mock.ctrl.T.Helper() 138 return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "HandleMaxStreamsFrame", reflect.TypeOf((*MockStreamManager)(nil).HandleMaxStreamsFrame), arg0) 139 } 140 141 // OpenStream mocks base method. 142 func (m *MockStreamManager) OpenStream() (Stream, error) { 143 m.ctrl.T.Helper() 144 ret := m.ctrl.Call(m, "OpenStream") 145 ret0, _ := ret[0].(Stream) 146 ret1, _ := ret[1].(error) 147 return ret0, ret1 148 } 149 150 // OpenStream indicates an expected call of OpenStream. 151 func (mr *MockStreamManagerMockRecorder) OpenStream() *gomock.Call { 152 mr.mock.ctrl.T.Helper() 153 return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "OpenStream", reflect.TypeOf((*MockStreamManager)(nil).OpenStream)) 154 } 155 156 // OpenStreamSync mocks base method. 157 func (m *MockStreamManager) OpenStreamSync(arg0 context.Context) (Stream, error) { 158 m.ctrl.T.Helper() 159 ret := m.ctrl.Call(m, "OpenStreamSync", arg0) 160 ret0, _ := ret[0].(Stream) 161 ret1, _ := ret[1].(error) 162 return ret0, ret1 163 } 164 165 // OpenStreamSync indicates an expected call of OpenStreamSync. 166 func (mr *MockStreamManagerMockRecorder) OpenStreamSync(arg0 any) *gomock.Call { 167 mr.mock.ctrl.T.Helper() 168 return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "OpenStreamSync", reflect.TypeOf((*MockStreamManager)(nil).OpenStreamSync), arg0) 169 } 170 171 // OpenUniStream mocks base method. 172 func (m *MockStreamManager) OpenUniStream() (SendStream, error) { 173 m.ctrl.T.Helper() 174 ret := m.ctrl.Call(m, "OpenUniStream") 175 ret0, _ := ret[0].(SendStream) 176 ret1, _ := ret[1].(error) 177 return ret0, ret1 178 } 179 180 // OpenUniStream indicates an expected call of OpenUniStream. 181 func (mr *MockStreamManagerMockRecorder) OpenUniStream() *gomock.Call { 182 mr.mock.ctrl.T.Helper() 183 return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "OpenUniStream", reflect.TypeOf((*MockStreamManager)(nil).OpenUniStream)) 184 } 185 186 // OpenUniStreamSync mocks base method. 187 func (m *MockStreamManager) OpenUniStreamSync(arg0 context.Context) (SendStream, error) { 188 m.ctrl.T.Helper() 189 ret := m.ctrl.Call(m, "OpenUniStreamSync", arg0) 190 ret0, _ := ret[0].(SendStream) 191 ret1, _ := ret[1].(error) 192 return ret0, ret1 193 } 194 195 // OpenUniStreamSync indicates an expected call of OpenUniStreamSync. 196 func (mr *MockStreamManagerMockRecorder) OpenUniStreamSync(arg0 any) *gomock.Call { 197 mr.mock.ctrl.T.Helper() 198 return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "OpenUniStreamSync", reflect.TypeOf((*MockStreamManager)(nil).OpenUniStreamSync), arg0) 199 } 200 201 // ResetFor0RTT mocks base method. 202 func (m *MockStreamManager) ResetFor0RTT() { 203 m.ctrl.T.Helper() 204 m.ctrl.Call(m, "ResetFor0RTT") 205 } 206 207 // ResetFor0RTT indicates an expected call of ResetFor0RTT. 208 func (mr *MockStreamManagerMockRecorder) ResetFor0RTT() *gomock.Call { 209 mr.mock.ctrl.T.Helper() 210 return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ResetFor0RTT", reflect.TypeOf((*MockStreamManager)(nil).ResetFor0RTT)) 211 } 212 213 // UpdateLimits mocks base method. 214 func (m *MockStreamManager) UpdateLimits(arg0 *wire.TransportParameters) { 215 m.ctrl.T.Helper() 216 m.ctrl.Call(m, "UpdateLimits", arg0) 217 } 218 219 // UpdateLimits indicates an expected call of UpdateLimits. 220 func (mr *MockStreamManagerMockRecorder) UpdateLimits(arg0 any) *gomock.Call { 221 mr.mock.ctrl.T.Helper() 222 return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "UpdateLimits", reflect.TypeOf((*MockStreamManager)(nil).UpdateLimits), arg0) 223 } 224 225 // UseResetMaps mocks base method. 226 func (m *MockStreamManager) UseResetMaps() { 227 m.ctrl.T.Helper() 228 m.ctrl.Call(m, "UseResetMaps") 229 } 230 231 // UseResetMaps indicates an expected call of UseResetMaps. 232 func (mr *MockStreamManagerMockRecorder) UseResetMaps() *gomock.Call { 233 mr.mock.ctrl.T.Helper() 234 return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "UseResetMaps", reflect.TypeOf((*MockStreamManager)(nil).UseResetMaps)) 235 }