This test fails from time to time in our CI. After investigation, it
turns out that sometimes the response comes just a few milliseconds
after the 3 seconds timeout has expired:
```
Got answer from 127.0.0.1:14191, relayed to 127.0.0.1:36139 (UDP), took 3.00105e+06 us
```
So let's use a slightly larger timeout of 4 seconds. It will not add
any delay if the response is received faster than that and will hopefully
reduce the number of spurious failures.
Signed-off-by: Remi Gacogne <remi.gacogne@powerdns.com>
for method in ("sendUDPQuery", "sendTCPQuery", "sendDOQQueryWrapper", "sendDOH3QueryWrapper", "sendDOTQueryWrapper", "sendDOHWithNGHTTP2QueryWrapper"):
sender = getattr(self, method)
- (_, receivedResponse) = sender(query, response=None, useQueue=False, timeout=3)
+ (_, receivedResponse) = sender(query, response=None, useQueue=False, timeout=4)
self.assertTrue(receivedResponse)
self.assertEqual(receivedResponse, expectedResponse)