Simulates connection failure so that we can test eviction of offline nodes
| 55 | |
| 56 | // Simulates connection failure so that we can test eviction of offline nodes |
| 57 | void SimConnFail(CService& addr) |
| 58 | { |
| 59 | int64_t nLastSuccess = 1; |
| 60 | Good_(addr, true, nLastSuccess); // Set last good connection in the deep past. |
| 61 | |
| 62 | bool count_failure = false; |
| 63 | int64_t nLastTry = GetAdjustedTime()-61; |
| 64 | Attempt(addr, count_failure, nLastTry); |
| 65 | } |
| 66 | }; |
| 67 | |
| 68 | static CNetAddr ResolveIP(const char* ip) |
no test coverage detected