(t *testing.T)
| 142 | } |
| 143 | |
| 144 | func TestList_Memory(t *testing.T) { |
| 145 | if !testutils.IsSingleTesting() { |
| 146 | return |
| 147 | } |
| 148 | |
| 149 | var list = expires.NewList() |
| 150 | |
| 151 | testutils.StartMemoryStats(t, func() { |
| 152 | t.Log(list.Count(), "items") |
| 153 | }) |
| 154 | |
| 155 | for i := 0; i < 10_000_000; i++ { |
| 156 | list.Add(uint64(i), time.Now().Unix()+1800) |
| 157 | } |
| 158 | |
| 159 | time.Sleep(1 * time.Hour) |
| 160 | } |
| 161 | |
| 162 | func TestList_Map_Performance(t *testing.T) { |
| 163 | t.Log("max uint32", math.MaxUint32) |
nothing calls this directly
no test coverage detected