var _ … type fakeCriteria … func (fc *fakeCriteria) GetMatchResources() v1.MatchResources { … } func (fc *fakeCriteria) GetParsedNamespaceSelector() (labels.Selector, error) { … } func (fc *fakeCriteria) GetParsedObjectSelector() (labels.Selector, error) { … } func gvr(group, version, resource string) schema.GroupVersionResource { … } func gvk(group, version, kind string) schema.GroupVersionKind { … } func TestMatcher(t *testing.T) { … } type fakeNamespaceLister … func (f fakeNamespaceLister) List(selector labels.Selector) (ret []*corev1.Namespace, err error) { … } func (f fakeNamespaceLister) Get(name string) (*corev1.Namespace, error) { … } func BenchmarkMatcher(b *testing.B) { … } func BenchmarkShouldCallHookWithComplexRule(b *testing.B) { … } func BenchmarkShouldCallHookWithComplexSelectorAndRule(b *testing.B) { … }