tests: port helper script revlog-formatv0.py to python 3
authorAugie Fackler <augie@google.com>
Thu, 01 Mar 2018 23:58:04 -0500
changeset 36565 9805c906aaad
parent 36564 c4ccc73f9d49
child 36566 ed96d1116302
tests: port helper script revlog-formatv0.py to python 3 Differential Revision: https://phab.mercurial-scm.org/D2540
tests/revlog-formatv0.py
--- a/tests/revlog-formatv0.py	Thu Mar 01 21:17:58 2018 -0500
+++ b/tests/revlog-formatv0.py	Thu Mar 01 23:58:04 2018 -0500
@@ -18,6 +18,7 @@
 """
 
 from __future__ import absolute_import
+import binascii
 import os
 import sys
 
@@ -56,7 +57,7 @@
 
 for name, data in files:
     f = open(name, 'wb')
-    f.write(data.decode('hex'))
+    f.write(binascii.unhexlify(data))
     f.close()
 
 sys.exit(0)