Merge pull request #30529 from hongchaodeng/r1

Automatic merge from submit-queue

change all PredicateFunc to use SelectionPredicate

What?
- This PR changes all PredicateFunc in registry to return SelectionPredicate instead of Matcher interface.

Why?
- We want to pass SelectionPredicate to storage layer. Matcher interface did not expose enough information for indexing.
This commit is contained in:
Kubernetes Submit Queue
2016-08-20 00:24:40 -07:00
committed by GitHub
58 changed files with 299 additions and 322 deletions

View File

@@ -20,14 +20,14 @@ import (
"testing"
"k8s.io/kubernetes/pkg/api"
"k8s.io/kubernetes/pkg/labels"
"k8s.io/kubernetes/pkg/fields"
)
// TestSelectableFieldLabelConversions verifies that given resource have field
// label conversion defined for each its selectable field.
// fields contains selectable fields of the resource.
// labelMap maps deprecated labels to their canonical names.
func TestSelectableFieldLabelConversionsOfKind(t *testing.T, apiVersion string, kind string, fields labels.Set, labelMap map[string]string) {
func TestSelectableFieldLabelConversionsOfKind(t *testing.T, apiVersion string, kind string, fields fields.Set, labelMap map[string]string) {
badFieldLabels := []string{
"name",
".name",