From 7d996aa97fa230cfe955d35f9db8f40a6ddf82c0 Mon Sep 17 00:00:00 2001 From: louisgong Date: Mon, 28 Oct 2019 21:30:32 +0800 Subject: [PATCH] fix TestInterPodAffinity case --- test/integration/scheduler/predicates_test.go | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/test/integration/scheduler/predicates_test.go b/test/integration/scheduler/predicates_test.go index 67b3e28c7d1..95f20d10bc3 100644 --- a/test/integration/scheduler/predicates_test.go +++ b/test/integration/scheduler/predicates_test.go @@ -64,7 +64,7 @@ func TestInterPodAffinity(t *testing.T) { cs := context.clientSet podLabel := map[string]string{"service": "securityscan"} - // podLabel2 := map[string]string{"security": "S1"} + podLabel2 := map[string]string{"security": "S1"} tests := []struct { pod *v1.Pod @@ -74,7 +74,7 @@ func TestInterPodAffinity(t *testing.T) { errorType string test string }{ - /*{ + { pod: &v1.Pod{ ObjectMeta: metav1.ObjectMeta{ Name: "fakename", @@ -91,7 +91,6 @@ func TestInterPodAffinity(t *testing.T) { { Key: "security", Operator: metav1.LabelSelectorOpDoesNotExist, - Values: []string{"securityscan"}, }, }, }, @@ -586,7 +585,7 @@ func TestInterPodAffinity(t *testing.T) { node: nodes[0], fits: false, test: "satisfies the PodAffinity but doesn't satisfies the PodAntiAffinity with the existing pod", - },*/ + }, { pod: &v1.Pod{ ObjectMeta: metav1.ObjectMeta{