From 86325a5f3e71c632dcafc8e4ace4072cd3e3434d Mon Sep 17 00:00:00 2001 From: andy pan Date: Wed, 23 May 2018 11:17:00 +0800 Subject: [PATCH] update - --- ants_test.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ants_test.go b/ants_test.go index 79a3a57..7e95097 100644 --- a/ants_test.go +++ b/ants_test.go @@ -30,7 +30,7 @@ import ( "github.com/panjf2000/ants" ) -var n = 100000 +var n = 10000000 //func demoFunc() { // var n int @@ -110,7 +110,7 @@ func TestAntsPoolWithFunc(t *testing.T) { t.Logf("running workers number:%d", p.Running()) mem := runtime.MemStats{} runtime.ReadMemStats(&mem) - t.Logf("memory usage:%d", mem.TotalAlloc/1024) + t.Logf("memory usage:%d", mem.TotalAlloc/GiB) } func TestNoPool(t *testing.T) { @@ -126,7 +126,7 @@ func TestNoPool(t *testing.T) { wg.Wait() mem := runtime.MemStats{} runtime.ReadMemStats(&mem) - t.Logf("memory usage:%d", mem.TotalAlloc/1024) + t.Logf("memory usage:%d", mem.TotalAlloc/GiB) } //func TestCustomPool(t *testing.T) {