Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Add timeout to async_producer_test
  • Loading branch information
horkhe committed Feb 13, 2018
1 parent e42dc76 commit 1596275
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion async_producer_test.go
Expand Up @@ -131,9 +131,12 @@ func TestAsyncProducer(t *testing.T) {
if msg.Metadata.(int) != i {
t.Error("Message metadata did not match")
}
case <-time.After(time.Second):
t.Errorf("Timeout waiting for msg #%d", i)
goto done
}
}

done:
closeProducer(t, producer)
leader.Close()
seedBroker.Close()
Expand Down

0 comments on commit 1596275

Please sign in to comment.