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