make read from channel other than stdout non-fatal

This commit is contained in:
Seth Jennings 2018-02-26 15:15:37 -06:00
parent 456ebf5de7
commit 0639f1def6

View File

@ -523,8 +523,14 @@ var _ = framework.KubeDescribe("Pods", func() {
continue continue
} }
if msg[0] != 1 { if msg[0] != 1 {
if len(msg) == 1 {
// skip an empty message on stream other than stdout
continue
} else {
framework.Failf("Got message from server that didn't start with channel 1 (STDOUT): %v", msg) framework.Failf("Got message from server that didn't start with channel 1 (STDOUT): %v", msg)
} }
}
buf.Write(msg[1:]) buf.Write(msg[1:])
} }
if buf.Len() == 0 { if buf.Len() == 0 {