forked from quic-go/quic-go
handshake: remove gomock tls.ClientSessionCache implementation (#4619)
This commit is contained in:
@@ -13,7 +13,3 @@ package mocks
|
||||
//go:generate sh -c "go run go.uber.org/mock/mockgen -typed -build_flags=\"-tags=gomock\" -package mocks -destination connection_flow_controller.go github.com/quic-go/quic-go/internal/flowcontrol ConnectionFlowController"
|
||||
//go:generate sh -c "go run go.uber.org/mock/mockgen -typed -build_flags=\"-tags=gomock\" -package mockackhandler -destination ackhandler/sent_packet_handler.go github.com/quic-go/quic-go/internal/ackhandler SentPacketHandler"
|
||||
//go:generate sh -c "go run go.uber.org/mock/mockgen -typed -build_flags=\"-tags=gomock\" -package mockackhandler -destination ackhandler/received_packet_handler.go github.com/quic-go/quic-go/internal/ackhandler ReceivedPacketHandler"
|
||||
|
||||
// The following command produces a warning message on OSX, however, it still generates the correct mock file.
|
||||
// See https://github.com/golang/mock/issues/339 for details.
|
||||
//go:generate sh -c "go run go.uber.org/mock/mockgen -typed -build_flags=\"-tags=gomock\" -package mocktls -destination tls/client_session_cache.go crypto/tls ClientSessionCache"
|
||||
|
||||
@@ -1,115 +0,0 @@
|
||||
// Code generated by MockGen. DO NOT EDIT.
|
||||
// Source: crypto/tls (interfaces: ClientSessionCache)
|
||||
//
|
||||
// Generated by this command:
|
||||
//
|
||||
// mockgen -typed -build_flags=-tags=gomock -package mocktls -destination tls/client_session_cache.go crypto/tls ClientSessionCache
|
||||
//
|
||||
|
||||
// Package mocktls is a generated GoMock package.
|
||||
package mocktls
|
||||
|
||||
import (
|
||||
tls "crypto/tls"
|
||||
reflect "reflect"
|
||||
|
||||
gomock "go.uber.org/mock/gomock"
|
||||
)
|
||||
|
||||
// MockClientSessionCache is a mock of ClientSessionCache interface.
|
||||
type MockClientSessionCache struct {
|
||||
ctrl *gomock.Controller
|
||||
recorder *MockClientSessionCacheMockRecorder
|
||||
}
|
||||
|
||||
// MockClientSessionCacheMockRecorder is the mock recorder for MockClientSessionCache.
|
||||
type MockClientSessionCacheMockRecorder struct {
|
||||
mock *MockClientSessionCache
|
||||
}
|
||||
|
||||
// NewMockClientSessionCache creates a new mock instance.
|
||||
func NewMockClientSessionCache(ctrl *gomock.Controller) *MockClientSessionCache {
|
||||
mock := &MockClientSessionCache{ctrl: ctrl}
|
||||
mock.recorder = &MockClientSessionCacheMockRecorder{mock}
|
||||
return mock
|
||||
}
|
||||
|
||||
// EXPECT returns an object that allows the caller to indicate expected use.
|
||||
func (m *MockClientSessionCache) EXPECT() *MockClientSessionCacheMockRecorder {
|
||||
return m.recorder
|
||||
}
|
||||
|
||||
// Get mocks base method.
|
||||
func (m *MockClientSessionCache) Get(arg0 string) (*tls.ClientSessionState, bool) {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "Get", arg0)
|
||||
ret0, _ := ret[0].(*tls.ClientSessionState)
|
||||
ret1, _ := ret[1].(bool)
|
||||
return ret0, ret1
|
||||
}
|
||||
|
||||
// Get indicates an expected call of Get.
|
||||
func (mr *MockClientSessionCacheMockRecorder) Get(arg0 any) *MockClientSessionCacheGetCall {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Get", reflect.TypeOf((*MockClientSessionCache)(nil).Get), arg0)
|
||||
return &MockClientSessionCacheGetCall{Call: call}
|
||||
}
|
||||
|
||||
// MockClientSessionCacheGetCall wrap *gomock.Call
|
||||
type MockClientSessionCacheGetCall struct {
|
||||
*gomock.Call
|
||||
}
|
||||
|
||||
// Return rewrite *gomock.Call.Return
|
||||
func (c *MockClientSessionCacheGetCall) Return(arg0 *tls.ClientSessionState, arg1 bool) *MockClientSessionCacheGetCall {
|
||||
c.Call = c.Call.Return(arg0, arg1)
|
||||
return c
|
||||
}
|
||||
|
||||
// Do rewrite *gomock.Call.Do
|
||||
func (c *MockClientSessionCacheGetCall) Do(f func(string) (*tls.ClientSessionState, bool)) *MockClientSessionCacheGetCall {
|
||||
c.Call = c.Call.Do(f)
|
||||
return c
|
||||
}
|
||||
|
||||
// DoAndReturn rewrite *gomock.Call.DoAndReturn
|
||||
func (c *MockClientSessionCacheGetCall) DoAndReturn(f func(string) (*tls.ClientSessionState, bool)) *MockClientSessionCacheGetCall {
|
||||
c.Call = c.Call.DoAndReturn(f)
|
||||
return c
|
||||
}
|
||||
|
||||
// Put mocks base method.
|
||||
func (m *MockClientSessionCache) Put(arg0 string, arg1 *tls.ClientSessionState) {
|
||||
m.ctrl.T.Helper()
|
||||
m.ctrl.Call(m, "Put", arg0, arg1)
|
||||
}
|
||||
|
||||
// Put indicates an expected call of Put.
|
||||
func (mr *MockClientSessionCacheMockRecorder) Put(arg0, arg1 any) *MockClientSessionCachePutCall {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Put", reflect.TypeOf((*MockClientSessionCache)(nil).Put), arg0, arg1)
|
||||
return &MockClientSessionCachePutCall{Call: call}
|
||||
}
|
||||
|
||||
// MockClientSessionCachePutCall wrap *gomock.Call
|
||||
type MockClientSessionCachePutCall struct {
|
||||
*gomock.Call
|
||||
}
|
||||
|
||||
// Return rewrite *gomock.Call.Return
|
||||
func (c *MockClientSessionCachePutCall) Return() *MockClientSessionCachePutCall {
|
||||
c.Call = c.Call.Return()
|
||||
return c
|
||||
}
|
||||
|
||||
// Do rewrite *gomock.Call.Do
|
||||
func (c *MockClientSessionCachePutCall) Do(f func(string, *tls.ClientSessionState)) *MockClientSessionCachePutCall {
|
||||
c.Call = c.Call.Do(f)
|
||||
return c
|
||||
}
|
||||
|
||||
// DoAndReturn rewrite *gomock.Call.DoAndReturn
|
||||
func (c *MockClientSessionCachePutCall) DoAndReturn(f func(string, *tls.ClientSessionState)) *MockClientSessionCachePutCall {
|
||||
c.Call = c.Call.DoAndReturn(f)
|
||||
return c
|
||||
}
|
||||
Reference in New Issue
Block a user