In the test suite, we use dig as a known sane DNS resolver to confirm that resolution works according to the rest of the world. In this use case, if the server doesn't respond within a very short timespan, it will not respond at all, but dig doesn't know this. The result is that failing tests take a long time to fail, rather than quickly showing you what went wrong.
Adjust the function that calls dig to support an explicit timeout as a kwarg, then make the test suite dig function call that with some short value.
In the test suite, we use dig as a known sane DNS resolver to confirm that resolution works according to the rest of the world. In this use case, if the server doesn't respond within a very short timespan, it will not respond at all, but dig doesn't know this. The result is that failing tests take a long time to fail, rather than quickly showing you what went wrong.
Adjust the function that calls dig to support an explicit timeout as a kwarg, then make the test suite dig function call that with some short value.