diff options
author | Wladimir J. van der Laan <laanwj@gmail.com> | 2016-01-18 10:45:52 +0100 |
---|---|---|
committer | Wladimir J. van der Laan <laanwj@gmail.com> | 2016-01-18 10:46:01 +0100 |
commit | 3ec5bb0a6e2ca3474fa90ce1d52a91a83b41a34c (patch) | |
tree | 68e6f64863b61a677593f837f03dbda0dd07582b /qa/rpc-tests/test_framework/script.py | |
parent | 5e00147838b0585aebdfd7533951f8708639bc9b (diff) | |
parent | 7777994846cdb9b9cf69e391a33eeed30393bbcf (diff) |
Merge pull request #7335
7777994 [qa] Fix pyton syntax in rpc tests (MarcoFalke)
Diffstat (limited to 'qa/rpc-tests/test_framework/script.py')
-rw-r--r-- | qa/rpc-tests/test_framework/script.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/qa/rpc-tests/test_framework/script.py b/qa/rpc-tests/test_framework/script.py index 0088876028..bf5e25fb27 100644 --- a/qa/rpc-tests/test_framework/script.py +++ b/qa/rpc-tests/test_framework/script.py @@ -14,7 +14,8 @@ Functionality to build scripts, as well as SignatureHash(). from __future__ import absolute_import, division, print_function, unicode_literals -from test_framework.mininode import CTransaction, CTxOut, hash256 +from .mininode import CTransaction, CTxOut, hash256 +from binascii import hexlify import sys bchr = chr @@ -24,10 +25,9 @@ if sys.version > '3': bchr = lambda x: bytes([x]) bord = lambda x: x -import copy import struct -from test_framework.bignum import bn2vch +from .bignum import bn2vch MAX_SCRIPT_SIZE = 10000 MAX_SCRIPT_ELEMENT_SIZE = 520 @@ -777,7 +777,7 @@ class CScript(bytes): # need to change def _repr(o): if isinstance(o, bytes): - return "x('%s')" % binascii.hexlify(o).decode('utf8') + return "x('%s')" % hexlify(o).decode('utf8') else: return repr(o) |