parallel test causes deadlock
This commit is contained in:
parent
dca078f30b
commit
a941a4772b
@ -30,15 +30,8 @@ func TestService(t *testing.T) {
|
|||||||
// we can't test service.Init as it parses the command line
|
// we can't test service.Init as it parses the command line
|
||||||
// service.Init()
|
// service.Init()
|
||||||
|
|
||||||
t.Run("Run", func(t *testing.T) {
|
|
||||||
t.Parallel()
|
|
||||||
|
|
||||||
// run service
|
// run service
|
||||||
service.Run()
|
go service.Run()
|
||||||
})
|
|
||||||
|
|
||||||
t.Run("Debug.Health", func(t *testing.T) {
|
|
||||||
t.Parallel()
|
|
||||||
|
|
||||||
// wait for start
|
// wait for start
|
||||||
wg.Wait()
|
wg.Wait()
|
||||||
@ -63,5 +56,4 @@ func TestService(t *testing.T) {
|
|||||||
|
|
||||||
// shutdown the service
|
// shutdown the service
|
||||||
cancel()
|
cancel()
|
||||||
})
|
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user