Mercurial > hg
diff mercurial/testing/__init__.py @ 47657:1bad89a67745
testing: do not stop waiting if timeout is 0 (issue6541)
Differential Revision: https://phab.mercurial-scm.org/D11102
author | Cédric Krier <ced@b2ck.com> |
---|---|
date | Sat, 17 Jul 2021 12:47:07 +0200 |
parents | 2dac94edd98d |
children | 5ad37164a8fe |
line wrap: on
line diff
--- a/mercurial/testing/__init__.py Thu Jul 08 22:04:31 2021 +0200 +++ b/mercurial/testing/__init__.py Sat Jul 17 12:47:07 2021 +0200 @@ -27,7 +27,7 @@ timeout *= _timeout_factor() start = time.time() while not os.path.exists(path): - if time.time() - start > timeout: + if timeout and time.time() - start > timeout: raise RuntimeError(b"timed out waiting for file: %s" % path) time.sleep(0.01)