(t *testing.T)
| 8 | ) |
| 9 | |
| 10 | func TestNewIPCacheMap(t *testing.T) { |
| 11 | var cacheMap = NewIPCacheMap(3) |
| 12 | |
| 13 | t.Log("====") |
| 14 | cacheMap.Add("1") |
| 15 | cacheMap.Add("2") |
| 16 | logs.PrintAsJSON(cacheMap.m, t) |
| 17 | logs.PrintAsJSON(cacheMap.list, t) |
| 18 | |
| 19 | t.Log("====") |
| 20 | cacheMap.Add("3") |
| 21 | logs.PrintAsJSON(cacheMap.m, t) |
| 22 | logs.PrintAsJSON(cacheMap.list, t) |
| 23 | |
| 24 | t.Log("====") |
| 25 | cacheMap.Add("4") |
| 26 | logs.PrintAsJSON(cacheMap.m, t) |
| 27 | logs.PrintAsJSON(cacheMap.list, t) |
| 28 | |
| 29 | t.Log("====") |
| 30 | cacheMap.Add("3") |
| 31 | logs.PrintAsJSON(cacheMap.m, t) |
| 32 | logs.PrintAsJSON(cacheMap.list, t) |
| 33 | } |
nothing calls this directly
no test coverage detected