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

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