Skip to content

Commit

Permalink
test/e2e_node: tie together expected string and exec
Browse files Browse the repository at this point in the history
This commit ties together busybox-sh invocation and test expectation
to avoid subtle mismatches between exec command and output string.
  • Loading branch information
lucab committed Jan 26, 2017
1 parent 373ff83 commit 05bff30
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions test/e2e_node/kubelet_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ var _ = framework.KubeDescribe("Kubelet", func() {
{
Image: "gcr.io/google_containers/busybox:1.24",
Name: podName,
Command: []string{"sh", "-c", "echo test > /file; sleep 240"},
Command: []string{"/bin/sh", "-c", "echo test > /file; sleep 240"},
SecurityContext: &v1.SecurityContext{
ReadOnlyRootFilesystem: &isReadOnly,
},
Expand All @@ -148,7 +148,7 @@ var _ = framework.KubeDescribe("Kubelet", func() {
buf := new(bytes.Buffer)
buf.ReadFrom(rc)
return buf.String()
}, time.Minute, time.Second*4).Should(Equal("sh: can't create /file: Read-only file system\n"))
}, time.Minute, time.Second*4).Should(Equal("/bin/sh: can't create /file: Read-only file system\n"))
})
})
})

0 comments on commit 05bff30

Please sign in to comment.