• Tim Peters's avatar
    checkTimeoutProvokingConflicts: try to fix rare failures. · 4659d8eb
    Tim Peters authored
    This always slept for 3 seconds, waiting for the storage to
    disconnect.  This loses on two counts:
    
    1. Since the timeout is set to 1 second, it typically sleeps
       longer than necessary.
    
    2. Since there's no predicting thread and process scheduling,
       3 seconds isn't always long enough, and rare failures have
       been reported against this test.
    
    Instead we do a polling loop now.  This typically succeeds in
    a little more than a second, speeding the normal case.  The
    loop will continue trying for up to a minute if not.
    4659d8eb
ConnectionTests.py 41.9 KB