Replace internal version of resource with external version for tests

This commit is contained in:
Sean Sullivan
2018-09-13 13:12:30 -07:00
parent 5e5f7e5389
commit 49852289de
12 changed files with 88 additions and 37 deletions

View File

@@ -29,7 +29,6 @@ import (
"k8s.io/apimachinery/pkg/watch"
fakeexternal "k8s.io/client-go/kubernetes/fake"
testcore "k8s.io/client-go/testing"
api "k8s.io/kubernetes/pkg/apis/core"
"k8s.io/kubernetes/pkg/controller"
)
@@ -119,18 +118,18 @@ func TestGetFirstPod(t *testing.T) {
watching: []watch.Event{
{
Type: watch.Modified,
Object: &api.Pod{
Object: &corev1.Pod{
ObjectMeta: metav1.ObjectMeta{
Name: "pod-1",
Namespace: metav1.NamespaceDefault,
CreationTimestamp: metav1.Date(2016, time.April, 1, 1, 0, 0, 0, time.UTC),
Labels: map[string]string{"test": "selector"},
},
Status: api.PodStatus{
Conditions: []api.PodCondition{
Status: corev1.PodStatus{
Conditions: []corev1.PodCondition{
{
Status: api.ConditionTrue,
Type: api.PodReady,
Status: corev1.ConditionTrue,
Type: corev1.PodReady,
},
},
},