~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/selftest/testhashcache.py

  • Committer: Martin Pool
  • Date: 2005-09-22 12:12:53 UTC
  • Revision ID: mbp@sourcefrog.net-20050922121253-eae2a3240ea5e493
- upgrade can no longer be done in current version branches
  so don't test it

Show diffs side-by-side

added added

removed removed

Lines of Context:
14
14
# along with this program; if not, write to the Free Software
15
15
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
16
16
 
17
 
import os
18
 
import time
19
17
from bzrlib.selftest import TestCaseInTempDir
20
18
 
21
19
 
27
25
 
28
26
def pause():
29
27
    if False:
30
 
        return
31
 
    if os.name == 'nt':
32
 
        time.sleep(3)
33
 
        return
34
 
    # allow it to stabilize
35
 
    start = int(time.time())
36
 
    while int(time.time()) == start:
37
 
        time.sleep(0.2)
 
28
        # enable this to get more accurate testing
 
29
        import time
 
30
        # allow it to stabilize
 
31
        start = int(time.time())
 
32
        while int(time.time()) == start:
 
33
            time.sleep(0.2)
38
34
    
39
35
 
40
36
class TestHashCache(TestCaseInTempDir):