changeset 34225:d43340bec0f5

tests: use int() instead of long() in test-pathencode.py
author Augie Fackler <raf@durin42.com>
date Sat, 16 Sep 2017 11:48:05 -0400
parents 0f200e2310ca
children cf08aaaea7f0
files tests/test-pathencode.py
diffstat 1 files changed, 3 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/tests/test-pathencode.py	Sat Sep 16 11:47:53 2017 -0400
+++ b/tests/test-pathencode.py	Sat Sep 16 11:48:05 2017 -0400
@@ -188,7 +188,7 @@
         if o in ('-c', '--count'):
             count = int(a)
         elif o in ('-s', '--seed'):
-            seed = long(a, base=0) # accepts base 10 or 16 strings
+            seed = int(a, base=0) # accepts base 10 or 16 strings
         elif o == '--build':
             buildprobtable(sys.stdout,
                            'find .hg/store/data -type f && '
@@ -197,9 +197,9 @@
 
     if seed is None:
         try:
-            seed = long(binascii.hexlify(os.urandom(16)), 16)
+            seed = int(binascii.hexlify(os.urandom(16)), 16)
         except AttributeError:
-            seed = long(time.time() * 1000)
+            seed = int(time.time() * 1000)
 
     rng = random.Random(seed)
     if runtests(rng, seed, count):