Skip to content

Commit

Permalink
fixing linter errors (#28)
Browse files Browse the repository at this point in the history
Signed-off-by: Ken Sipe <kensipe@gmail.com>
  • Loading branch information
kensipe committed Mar 23, 2020
1 parent 043d4b1 commit a03c0f1
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 28 deletions.
56 changes: 28 additions & 28 deletions pkg/test/step_test.go
Expand Up @@ -255,43 +255,43 @@ func TestRun(t *testing.T) {
updateMethod func(*testing.T, client.Client)
}{
{
"successful run", false, Step{
Apply: []runtime.Object{
testutils.NewPod("hello", ""),
},
Asserts: []runtime.Object{
testutils.NewPod("hello", ""),
testName: "successful run", Step: Step{
Apply: []runtime.Object{
testutils.NewPod("hello", ""),
},
Asserts: []runtime.Object{
testutils.NewPod("hello", ""),
},
},
}, nil,
},
{
"failed run", true, Step{
Apply: []runtime.Object{
testutils.NewPod("hello", ""),
},
Asserts: []runtime.Object{
testutils.WithStatus(t, testutils.NewPod("hello", ""), map[string]interface{}{
"phase": "Ready",
}),
},
}, nil,
Apply: []runtime.Object{
testutils.NewPod("hello", ""),
},
Asserts: []runtime.Object{
testutils.WithStatus(t, testutils.NewPod("hello", ""), map[string]interface{}{
"phase": "Ready",
}),
},
}, nil,
},
{
"delayed run", false, Step{
Apply: []runtime.Object{
testutils.NewPod("hello", ""),
},
Asserts: []runtime.Object{
testutils.WithStatus(t, testutils.NewPod("hello", ""), map[string]interface{}{
Apply: []runtime.Object{
testutils.NewPod("hello", ""),
},
Asserts: []runtime.Object{
testutils.WithStatus(t, testutils.NewPod("hello", ""), map[string]interface{}{
"phase": "Ready",
}),
},
}, func(t *testing.T, client client.Client) {
// mock kubelet to set the pod status
assert.Nil(t, client.Update(context.TODO(), testutils.WithStatus(t, testutils.NewPod("hello", testNamespace), map[string]interface{}{
"phase": "Ready",
}),
})))
},
}, func(t *testing.T, client client.Client) {
// mock kubelet to set the pod status
assert.Nil(t, client.Update(context.TODO(), testutils.WithStatus(t, testutils.NewPod("hello", testNamespace), map[string]interface{}{
"phase": "Ready",
})))
},
},
} {
test := test
Expand Down
1 change: 1 addition & 0 deletions pkg/test/utils/kubernetes.go
Expand Up @@ -72,6 +72,7 @@ var APIServerDefaultArgs = []string{
"--admission-control=AlwaysAdmit",
"--service-cluster-ip-range=10.0.0.0/24",
}

//TODO (kensipe): need to consider options around AlwaysAdmin https://github.com/kudobuilder/kudo/pull/1420/files#r391449597

// IsJSONSyntaxError returns true if the error is a JSON syntax error.
Expand Down

0 comments on commit a03c0f1

Please sign in to comment.