Fix test issue in Go 1.5

This commit is contained in:
Wojciech Tyczynski
2015-12-18 11:27:05 +01:00
parent 8b3c5f97ff
commit 96b5ca0cc5

View File

@@ -227,8 +227,8 @@ func TestWatchEtcdError(t *testing.T) {
} }
server.Terminate(t) server.Terminate(t)
got := <-watching.ResultChan() got, ok := <-watching.ResultChan()
if got.Type != watch.Error { if ok && got.Type != watch.Error {
t.Fatalf("Unexpected non-error") t.Fatalf("Unexpected non-error")
} }
watching.Stop() watching.Stop()