(t *testing.T)
| 164 | } |
| 165 | |
| 166 | func TestGetCacheSize(t *testing.T) { |
| 167 | r := New(100 * time.Millisecond) |
| 168 | |
| 169 | if r.GetCacheSize() != 0 { |
| 170 | t.Errorf("expected initial cache size 0, got %d", r.GetCacheSize()) |
| 171 | } |
| 172 | |
| 173 | r.ResolveAddr("127.0.0.1") |
| 174 | if r.GetCacheSize() != 1 { |
| 175 | t.Errorf("expected cache size 1, got %d", r.GetCacheSize()) |
| 176 | } |
| 177 | } |
| 178 | |
| 179 | func TestGetServiceName(t *testing.T) { |
| 180 | tests := []struct { |
nothing calls this directly
no test coverage detected