aboutsummaryrefslogtreecommitdiff
path: root/test/functional/mining_basic.py
diff options
context:
space:
mode:
authorAkio Nakamura <nakamura@dgtechnologies.co.jp>2019-02-19 15:03:46 +0900
committerAkio Nakamura <nakamura@dgtechnologies.co.jp>2019-02-19 16:38:44 +0900
commit1a062b85f0f445d786c658a4f3687c07011810dc (patch)
treeaf1614c6939975a9c0ad68d090fd6443f0c41cec /test/functional/mining_basic.py
parent904308dca3ff50afb704597c0a65d226dd40f635 (diff)
tests: remove byte.hex() to keep compatibility
Use test_framework.util.bytes_to_hex_str() instead of bytes.hex() that new in Python 3.5, to support minimum version of Python(test).
Diffstat (limited to 'test/functional/mining_basic.py')
-rwxr-xr-xtest/functional/mining_basic.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/test/functional/mining_basic.py b/test/functional/mining_basic.py
index df8fe23a2e..d0bef48cb6 100755
--- a/test/functional/mining_basic.py
+++ b/test/functional/mining_basic.py
@@ -184,7 +184,7 @@ class MiningTest(BitcoinTestFramework):
self.log.info('submitheader tests')
assert_raises_rpc_error(-22, 'Block header decode failed', lambda: node.submitheader(hexdata='xx' * BLOCK_HEADER_SIZE))
assert_raises_rpc_error(-22, 'Block header decode failed', lambda: node.submitheader(hexdata='ff' * (BLOCK_HEADER_SIZE-2)))
- assert_raises_rpc_error(-25, 'Must submit previous header', lambda: node.submitheader(hexdata=super(CBlock, bad_block).serialize().hex()))
+ assert_raises_rpc_error(-25, 'Must submit previous header', lambda: node.submitheader(hexdata=b2x(super(CBlock, bad_block).serialize())))
block.nTime += 1
block.solve()