diff options
Diffstat (limited to 'pool/supervisor_test.go')
-rw-r--r-- | pool/supervisor_test.go | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/pool/supervisor_test.go b/pool/supervisor_test.go index c3abf85e..9c0bfdaa 100644 --- a/pool/supervisor_test.go +++ b/pool/supervisor_test.go @@ -265,6 +265,11 @@ func TestSupervisedPool_IdleTTL_StateAfterTimeout(t *testing.T) { assert.Empty(t, resp.Context) time.Sleep(time.Second * 2) + + if len(p.Workers()) < 1 { + t.Fatal("should be at least 1 worker") + return + } // should be destroyed, state should be Ready, not Invalid assert.NotEqual(t, pid, p.Workers()[0].Pid()) assert.Equal(t, int64(1), p.Workers()[0].State().Value()) |