1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159
|
// Code generated by MockGen. DO NOT EDIT.
// Source: k8s.io/cli-runtime/pkg/resource (interfaces: RESTClientGetter)
//
// Generated by this command:
//
// mockgen -typed -destination resource.go -package mock_k8s k8s.io/cli-runtime/pkg/resource RESTClientGetter
//
// Package mock_k8s is a generated GoMock package.
package mock_k8s
import (
reflect "reflect"
gomock "go.uber.org/mock/gomock"
meta "k8s.io/apimachinery/pkg/api/meta"
discovery "k8s.io/client-go/discovery"
rest "k8s.io/client-go/rest"
)
// MockRESTClientGetter is a mock of RESTClientGetter interface.
type MockRESTClientGetter struct {
ctrl *gomock.Controller
recorder *MockRESTClientGetterMockRecorder
}
// MockRESTClientGetterMockRecorder is the mock recorder for MockRESTClientGetter.
type MockRESTClientGetterMockRecorder struct {
mock *MockRESTClientGetter
}
// NewMockRESTClientGetter creates a new mock instance.
func NewMockRESTClientGetter(ctrl *gomock.Controller) *MockRESTClientGetter {
mock := &MockRESTClientGetter{ctrl: ctrl}
mock.recorder = &MockRESTClientGetterMockRecorder{mock}
return mock
}
// EXPECT returns an object that allows the caller to indicate expected use.
func (m *MockRESTClientGetter) EXPECT() *MockRESTClientGetterMockRecorder {
return m.recorder
}
// ToDiscoveryClient mocks base method.
func (m *MockRESTClientGetter) ToDiscoveryClient() (discovery.CachedDiscoveryInterface, error) {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "ToDiscoveryClient")
ret0, _ := ret[0].(discovery.CachedDiscoveryInterface)
ret1, _ := ret[1].(error)
return ret0, ret1
}
// ToDiscoveryClient indicates an expected call of ToDiscoveryClient.
func (mr *MockRESTClientGetterMockRecorder) ToDiscoveryClient() *MockRESTClientGetterToDiscoveryClientCall {
mr.mock.ctrl.T.Helper()
call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ToDiscoveryClient", reflect.TypeOf((*MockRESTClientGetter)(nil).ToDiscoveryClient))
return &MockRESTClientGetterToDiscoveryClientCall{Call: call}
}
// MockRESTClientGetterToDiscoveryClientCall wrap *gomock.Call
type MockRESTClientGetterToDiscoveryClientCall struct {
*gomock.Call
}
// Return rewrite *gomock.Call.Return
func (c *MockRESTClientGetterToDiscoveryClientCall) Return(arg0 discovery.CachedDiscoveryInterface, arg1 error) *MockRESTClientGetterToDiscoveryClientCall {
c.Call = c.Call.Return(arg0, arg1)
return c
}
// Do rewrite *gomock.Call.Do
func (c *MockRESTClientGetterToDiscoveryClientCall) Do(f func() (discovery.CachedDiscoveryInterface, error)) *MockRESTClientGetterToDiscoveryClientCall {
c.Call = c.Call.Do(f)
return c
}
// DoAndReturn rewrite *gomock.Call.DoAndReturn
func (c *MockRESTClientGetterToDiscoveryClientCall) DoAndReturn(f func() (discovery.CachedDiscoveryInterface, error)) *MockRESTClientGetterToDiscoveryClientCall {
c.Call = c.Call.DoAndReturn(f)
return c
}
// ToRESTConfig mocks base method.
func (m *MockRESTClientGetter) ToRESTConfig() (*rest.Config, error) {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "ToRESTConfig")
ret0, _ := ret[0].(*rest.Config)
ret1, _ := ret[1].(error)
return ret0, ret1
}
// ToRESTConfig indicates an expected call of ToRESTConfig.
func (mr *MockRESTClientGetterMockRecorder) ToRESTConfig() *MockRESTClientGetterToRESTConfigCall {
mr.mock.ctrl.T.Helper()
call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ToRESTConfig", reflect.TypeOf((*MockRESTClientGetter)(nil).ToRESTConfig))
return &MockRESTClientGetterToRESTConfigCall{Call: call}
}
// MockRESTClientGetterToRESTConfigCall wrap *gomock.Call
type MockRESTClientGetterToRESTConfigCall struct {
*gomock.Call
}
// Return rewrite *gomock.Call.Return
func (c *MockRESTClientGetterToRESTConfigCall) Return(arg0 *rest.Config, arg1 error) *MockRESTClientGetterToRESTConfigCall {
c.Call = c.Call.Return(arg0, arg1)
return c
}
// Do rewrite *gomock.Call.Do
func (c *MockRESTClientGetterToRESTConfigCall) Do(f func() (*rest.Config, error)) *MockRESTClientGetterToRESTConfigCall {
c.Call = c.Call.Do(f)
return c
}
// DoAndReturn rewrite *gomock.Call.DoAndReturn
func (c *MockRESTClientGetterToRESTConfigCall) DoAndReturn(f func() (*rest.Config, error)) *MockRESTClientGetterToRESTConfigCall {
c.Call = c.Call.DoAndReturn(f)
return c
}
// ToRESTMapper mocks base method.
func (m *MockRESTClientGetter) ToRESTMapper() (meta.RESTMapper, error) {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "ToRESTMapper")
ret0, _ := ret[0].(meta.RESTMapper)
ret1, _ := ret[1].(error)
return ret0, ret1
}
// ToRESTMapper indicates an expected call of ToRESTMapper.
func (mr *MockRESTClientGetterMockRecorder) ToRESTMapper() *MockRESTClientGetterToRESTMapperCall {
mr.mock.ctrl.T.Helper()
call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ToRESTMapper", reflect.TypeOf((*MockRESTClientGetter)(nil).ToRESTMapper))
return &MockRESTClientGetterToRESTMapperCall{Call: call}
}
// MockRESTClientGetterToRESTMapperCall wrap *gomock.Call
type MockRESTClientGetterToRESTMapperCall struct {
*gomock.Call
}
// Return rewrite *gomock.Call.Return
func (c *MockRESTClientGetterToRESTMapperCall) Return(arg0 meta.RESTMapper, arg1 error) *MockRESTClientGetterToRESTMapperCall {
c.Call = c.Call.Return(arg0, arg1)
return c
}
// Do rewrite *gomock.Call.Do
func (c *MockRESTClientGetterToRESTMapperCall) Do(f func() (meta.RESTMapper, error)) *MockRESTClientGetterToRESTMapperCall {
c.Call = c.Call.Do(f)
return c
}
// DoAndReturn rewrite *gomock.Call.DoAndReturn
func (c *MockRESTClientGetterToRESTMapperCall) DoAndReturn(f func() (meta.RESTMapper, error)) *MockRESTClientGetterToRESTMapperCall {
c.Call = c.Call.DoAndReturn(f)
return c
}
|