mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-09-20 01:23:48 +00:00
Merge pull request #21335 from deads2k/make-rc-logs-work
Auto commit by PR queue bot
This commit is contained in:
@@ -464,7 +464,7 @@ var _ = Describe("Kubectl client", func() {
|
||||
withStdinData("abcd1234\n").
|
||||
execOrDie()
|
||||
Expect(runOutput).ToNot(ContainSubstring("stdin closed"))
|
||||
runTestPod, err := util.GetFirstPod(c, ns, labels.SelectorFromSet(map[string]string{"run": "run-test-3"}))
|
||||
runTestPod, _, err := util.GetFirstPod(c, ns, labels.SelectorFromSet(map[string]string{"run": "run-test-3"}))
|
||||
if err != nil {
|
||||
os.Exit(1)
|
||||
}
|
||||
@@ -898,6 +898,13 @@ var _ = Describe("Kubectl client", func() {
|
||||
runKubectlOrDie("get", "pods", "-L", "run", nsFlag)
|
||||
Failf("Failed creating 1 pod with expected image %s. Number of pods = %v", nginxImage, len(pods))
|
||||
}
|
||||
|
||||
By("confirm that you can get logs from an rc")
|
||||
_, err = runKubectl("logs", "rc/"+rcName, nsFlag)
|
||||
// a non-nil error is fine as long as we actually found a pod.
|
||||
if err != nil && !strings.Contains(err.Error(), " in pod ") {
|
||||
Failf("Failed getting logs by rc %s: %v", rcName, err)
|
||||
}
|
||||
})
|
||||
|
||||
})
|
||||
|
Reference in New Issue
Block a user