Use reconnect timeout on client (#12)

This commit is contained in:
Serene Han 2016-02-17 19:53:11 -08:00
parent f205a0be59
commit 8a2e7a6041
3 changed files with 36 additions and 25 deletions

View file

@ -39,6 +39,13 @@ func TestConnect(t *testing.T) {
So(mock.destination.Bytes(), ShouldResemble, []byte("test"))
})
Convey("Receive answer fails on nil answer", func() {
c.reset = make(chan struct{})
c.ReceiveAnswer()
answerChannel <- nil
<-c.reset
})
Convey("Connect Loop", func() {
// TODO
})