Documentation ¶
Index ¶
- Constants
- Variables
- type MockManager
- func (m *MockManager) AddForeignEntry(namespace string, api apimgmt.ApiType, obj v1.Object)
- func (m *MockManager) AddForeignEventHandlers(apiType apimgmt.ApiType, s string, funcs *cache.ResourceEventHandlerFuncs) error
- func (m *MockManager) AddForeignNamespace(s string) error
- func (m *MockManager) AddHomeEntry(namespace string, api apimgmt.ApiType, obj v1.Object)
- func (m *MockManager) AddHomeEventHandlers(apiType apimgmt.ApiType, s string, funcs *cache.ResourceEventHandlerFuncs) error
- func (m *MockManager) AddHomeNamespace(s string) error
- func (m *MockManager) CheckNamespaceCaching(_ *wait.Backoff, _ string, _ string, _ apimgmt.ApiType) error
- func (m *MockManager) Clear()
- func (m *MockManager) GetForeignAPIByIndex(apiType apimgmt.ApiType, s, s2 string) (interface{}, error)
- func (m *MockManager) GetForeignNamespacedObject(apiType apimgmt.ApiType, s string, s2 string) (interface{}, error)
- func (m *MockManager) GetHomeAPIByIndex(apiType apimgmt.ApiType, s, s2 string) (interface{}, error)
- func (m *MockManager) GetHomeNamespacedObject(apiType apimgmt.ApiType, s string, s2 string) (interface{}, error)
- func (m *MockManager) ListForeignNamespacedObject(apiType apimgmt.ApiType, s string) ([]interface{}, error)
- func (m *MockManager) ListHomeNamespacedObject(apiType apimgmt.ApiType, s string) ([]interface{}, error)
- func (m *MockManager) RemoveNamespace(s string)
- func (m *MockManager) ResyncListForeignNamespacedObject(apiType apimgmt.ApiType, s string) ([]interface{}, error)
- func (m *MockManager) ResyncListHomeNamespacedObject(apiType apimgmt.ApiType, s string) ([]interface{}, error)
- func (m *MockManager) StartForeignNamespace(s string, c chan struct{}) error
- func (m *MockManager) StartHomeNamespace(s string, c chan struct{}) error
Constants ¶
View Source
const ( HomeNamespace = "homeNamespace" ForeignNamespace = "foreignNamespace" Pod1 = "homePod1" Pod2 = "homePod2" )
Variables ¶
View Source
var ( Pods = map[string]*corev1.Pod{ utils.Keyer(HomeNamespace, Pod1): { ObjectMeta: metav1.ObjectMeta{ Name: Pod1, Namespace: HomeNamespace, }, }, utils.Keyer(HomeNamespace, Pod2): { ObjectMeta: metav1.ObjectMeta{ Name: Pod2, Namespace: HomeNamespace, }, }, utils.Keyer(ForeignNamespace, Pod1): { ObjectMeta: metav1.ObjectMeta{ Name: Pod1, Namespace: ForeignNamespace, }, }, utils.Keyer(ForeignNamespace, Pod2): { ObjectMeta: metav1.ObjectMeta{ Name: Pod2, Namespace: ForeignNamespace, }, }, } )
Functions ¶
This section is empty.
Types ¶
type MockManager ¶
type MockManager struct { HomeCache map[string]map[apimgmt.ApiType]map[string]v1.Object ForeignCache map[string]map[apimgmt.ApiType]map[string]v1.Object }
func (*MockManager) AddForeignEntry ¶
func (*MockManager) AddForeignEventHandlers ¶
func (m *MockManager) AddForeignEventHandlers(apiType apimgmt.ApiType, s string, funcs *cache.ResourceEventHandlerFuncs) error
func (*MockManager) AddForeignNamespace ¶
func (m *MockManager) AddForeignNamespace(s string) error
func (*MockManager) AddHomeEntry ¶
func (*MockManager) AddHomeEventHandlers ¶
func (m *MockManager) AddHomeEventHandlers(apiType apimgmt.ApiType, s string, funcs *cache.ResourceEventHandlerFuncs) error
func (*MockManager) AddHomeNamespace ¶
func (m *MockManager) AddHomeNamespace(s string) error
func (*MockManager) CheckNamespaceCaching ¶
func (*MockManager) Clear ¶ added in v0.3.0
func (m *MockManager) Clear()
Clear is a function used in tests only to clear the mock's state.
func (*MockManager) GetForeignAPIByIndex ¶ added in v0.3.0
func (m *MockManager) GetForeignAPIByIndex(apiType apimgmt.ApiType, s, s2 string) (interface{}, error)
GetForeignAPIByIndex is a mock implementation of the corresponding function (unimplemented).
func (*MockManager) GetForeignNamespacedObject ¶
func (*MockManager) GetHomeAPIByIndex ¶ added in v0.3.0
func (m *MockManager) GetHomeAPIByIndex(apiType apimgmt.ApiType, s, s2 string) (interface{}, error)
GetHomeAPIByIndex is a mock implementation of the corresponding function (unimplemented).
func (*MockManager) GetHomeNamespacedObject ¶
func (*MockManager) ListForeignNamespacedObject ¶
func (m *MockManager) ListForeignNamespacedObject(apiType apimgmt.ApiType, s string) ([]interface{}, error)
func (*MockManager) ListHomeNamespacedObject ¶
func (m *MockManager) ListHomeNamespacedObject(apiType apimgmt.ApiType, s string) ([]interface{}, error)
func (*MockManager) RemoveNamespace ¶
func (m *MockManager) RemoveNamespace(s string)
func (*MockManager) ResyncListForeignNamespacedObject ¶
func (m *MockManager) ResyncListForeignNamespacedObject(apiType apimgmt.ApiType, s string) ([]interface{}, error)
func (*MockManager) ResyncListHomeNamespacedObject ¶
func (m *MockManager) ResyncListHomeNamespacedObject(apiType apimgmt.ApiType, s string) ([]interface{}, error)
func (*MockManager) StartForeignNamespace ¶
func (m *MockManager) StartForeignNamespace(s string, c chan struct{}) error
func (*MockManager) StartHomeNamespace ¶
func (m *MockManager) StartHomeNamespace(s string, c chan struct{}) error
Click to show internal directories.
Click to hide internal directories.