Move extensions.LabelSelector to unversioned.

Move type LabelSelector and type LabelSelectorRequirement from pkg/apis/extensions
This avoids an import loop when Job (and later DaemonSet, Deployment, ReplicaSet)
are moved out of extensions to new api groups.

Also Move LabelSelectorAsSelector utility from pkg/apis/extensions/ to pkg/api/unversioned/
Also its test.
Also LabelSelectorOp* constants.
Also the pkg/apis/extensions/validation functions ValidateLabelSelectorRequirement and
ValidateLabelSelector move to pkg/api/unversioned

The related type in pkg/apis/extensions/v1beta1/ is staying there.  I might move
it in another PR if neccessary.
This commit is contained in:
Eric Tune
2016-02-01 21:34:42 -08:00
parent ad9fa30e7e
commit 6133cb1f21
29 changed files with 316 additions and 246 deletions

View File

@@ -267,7 +267,7 @@ func TestMonitorNodeStatusEvictPods(t *testing.T) {
Namespace: "default",
},
Spec: extensions.DaemonSetSpec{
Selector: &extensions.LabelSelector{
Selector: &unversioned.LabelSelector{
MatchLabels: map[string]string{"daemon": "yes"},
},
},