parallel test causes deadlock
This commit is contained in:
		| @@ -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() | ||||||
| 	}) |  | ||||||
| } | } | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user