Retry client connections in selftest
authorJeremy Stanley <fungi@yuggoth.org>
Sat, 17 Apr 2021 16:07:33 +0000 (16:07 +0000)
committerJeremy Stanley <fungi@yuggoth.org>
Sat, 24 Apr 2021 13:31:41 +0000 (13:31 +0000)
commit743c99fee8de7db57253daa15602bb4af6f85eda
treeef23661736f8ef2ebf801f31b910cce83d85c6fb
parent3679895b52c48070dd874b92e2b7e01dcd232feb
Retry client connections in selftest

Replace a hard-coded delay after process start with a dynamic client
connection retry, which attempts to connect up to five times with
the first being immediate while subsequent connections observe an
exponential backoff over a three-second period before giving up.
This improves both speed and stability of test runs.

Also combine the ConnectionResetError and EOFError conditions which
could be raised later once the socket is in use, as the end result
of either is effectively the same.
mudpy/tests/selftest.py