mock_packer_test.go 4.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120
  1. // Code generated by MockGen. DO NOT EDIT.
  2. // Source: github.com/lucas-clemente/quic-go (interfaces: Packer)
  3. // Package quic is a generated GoMock package.
  4. package quic
  5. import (
  6. reflect "reflect"
  7. gomock "github.com/golang/mock/gomock"
  8. ackhandler "github.com/lucas-clemente/quic-go/internal/ackhandler"
  9. handshake "github.com/lucas-clemente/quic-go/internal/handshake"
  10. protocol "github.com/lucas-clemente/quic-go/internal/protocol"
  11. wire "github.com/lucas-clemente/quic-go/internal/wire"
  12. )
  13. // MockPacker is a mock of Packer interface
  14. type MockPacker struct {
  15. ctrl *gomock.Controller
  16. recorder *MockPackerMockRecorder
  17. }
  18. // MockPackerMockRecorder is the mock recorder for MockPacker
  19. type MockPackerMockRecorder struct {
  20. mock *MockPacker
  21. }
  22. // NewMockPacker creates a new mock instance
  23. func NewMockPacker(ctrl *gomock.Controller) *MockPacker {
  24. mock := &MockPacker{ctrl: ctrl}
  25. mock.recorder = &MockPackerMockRecorder{mock}
  26. return mock
  27. }
  28. // EXPECT returns an object that allows the caller to indicate expected use
  29. func (m *MockPacker) EXPECT() *MockPackerMockRecorder {
  30. return m.recorder
  31. }
  32. // ChangeDestConnectionID mocks base method
  33. func (m *MockPacker) ChangeDestConnectionID(arg0 protocol.ConnectionID) {
  34. m.ctrl.Call(m, "ChangeDestConnectionID", arg0)
  35. }
  36. // ChangeDestConnectionID indicates an expected call of ChangeDestConnectionID
  37. func (mr *MockPackerMockRecorder) ChangeDestConnectionID(arg0 interface{}) *gomock.Call {
  38. return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ChangeDestConnectionID", reflect.TypeOf((*MockPacker)(nil).ChangeDestConnectionID), arg0)
  39. }
  40. // HandleTransportParameters mocks base method
  41. func (m *MockPacker) HandleTransportParameters(arg0 *handshake.TransportParameters) {
  42. m.ctrl.Call(m, "HandleTransportParameters", arg0)
  43. }
  44. // HandleTransportParameters indicates an expected call of HandleTransportParameters
  45. func (mr *MockPackerMockRecorder) HandleTransportParameters(arg0 interface{}) *gomock.Call {
  46. return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "HandleTransportParameters", reflect.TypeOf((*MockPacker)(nil).HandleTransportParameters), arg0)
  47. }
  48. // MaybePackAckPacket mocks base method
  49. func (m *MockPacker) MaybePackAckPacket() (*packedPacket, error) {
  50. ret := m.ctrl.Call(m, "MaybePackAckPacket")
  51. ret0, _ := ret[0].(*packedPacket)
  52. ret1, _ := ret[1].(error)
  53. return ret0, ret1
  54. }
  55. // MaybePackAckPacket indicates an expected call of MaybePackAckPacket
  56. func (mr *MockPackerMockRecorder) MaybePackAckPacket() *gomock.Call {
  57. return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "MaybePackAckPacket", reflect.TypeOf((*MockPacker)(nil).MaybePackAckPacket))
  58. }
  59. // PackConnectionClose mocks base method
  60. func (m *MockPacker) PackConnectionClose(arg0 *wire.ConnectionCloseFrame) (*packedPacket, error) {
  61. ret := m.ctrl.Call(m, "PackConnectionClose", arg0)
  62. ret0, _ := ret[0].(*packedPacket)
  63. ret1, _ := ret[1].(error)
  64. return ret0, ret1
  65. }
  66. // PackConnectionClose indicates an expected call of PackConnectionClose
  67. func (mr *MockPackerMockRecorder) PackConnectionClose(arg0 interface{}) *gomock.Call {
  68. return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "PackConnectionClose", reflect.TypeOf((*MockPacker)(nil).PackConnectionClose), arg0)
  69. }
  70. // PackPacket mocks base method
  71. func (m *MockPacker) PackPacket() (*packedPacket, error) {
  72. ret := m.ctrl.Call(m, "PackPacket")
  73. ret0, _ := ret[0].(*packedPacket)
  74. ret1, _ := ret[1].(error)
  75. return ret0, ret1
  76. }
  77. // PackPacket indicates an expected call of PackPacket
  78. func (mr *MockPackerMockRecorder) PackPacket() *gomock.Call {
  79. return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "PackPacket", reflect.TypeOf((*MockPacker)(nil).PackPacket))
  80. }
  81. // PackRetransmission mocks base method
  82. func (m *MockPacker) PackRetransmission(arg0 *ackhandler.Packet) ([]*packedPacket, error) {
  83. ret := m.ctrl.Call(m, "PackRetransmission", arg0)
  84. ret0, _ := ret[0].([]*packedPacket)
  85. ret1, _ := ret[1].(error)
  86. return ret0, ret1
  87. }
  88. // PackRetransmission indicates an expected call of PackRetransmission
  89. func (mr *MockPackerMockRecorder) PackRetransmission(arg0 interface{}) *gomock.Call {
  90. return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "PackRetransmission", reflect.TypeOf((*MockPacker)(nil).PackRetransmission), arg0)
  91. }
  92. // SetToken mocks base method
  93. func (m *MockPacker) SetToken(arg0 []byte) {
  94. m.ctrl.Call(m, "SetToken", arg0)
  95. }
  96. // SetToken indicates an expected call of SetToken
  97. func (mr *MockPackerMockRecorder) SetToken(arg0 interface{}) *gomock.Call {
  98. return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SetToken", reflect.TypeOf((*MockPacker)(nil).SetToken), arg0)
  99. }