forked from mirror/ants
update
This commit is contained in:
parent
23c80e1158
commit
cc81c9573f
|
@ -43,7 +43,7 @@ func TestAntsPoolWithFunc(t *testing.T) {
|
||||||
|
|
||||||
for i := 0; i < n; i++ {
|
for i := 0; i < n; i++ {
|
||||||
wg.Add(1)
|
wg.Add(1)
|
||||||
p.Serve(n)
|
p.Serve(Param)
|
||||||
}
|
}
|
||||||
wg.Wait()
|
wg.Wait()
|
||||||
|
|
||||||
|
@ -98,7 +98,7 @@ func TestCodeCov(t *testing.T) {
|
||||||
p, _ := ants.NewPoolWithFunc(AntsSize, demoPoolFunc)
|
p, _ := ants.NewPoolWithFunc(AntsSize, demoPoolFunc)
|
||||||
defer p.Release()
|
defer p.Release()
|
||||||
for i := 0; i < n; i++ {
|
for i := 0; i < n; i++ {
|
||||||
p.Serve(n)
|
p.Serve(Param)
|
||||||
}
|
}
|
||||||
t.Logf("pool with func, capacity:%d", p.Cap())
|
t.Logf("pool with func, capacity:%d", p.Cap())
|
||||||
t.Logf("pool with func, running workers number:%d", p.Running())
|
t.Logf("pool with func, running workers number:%d", p.Running())
|
||||||
|
|
Loading…
Reference in New Issue