Skip to content

Commit

Permalink
Use FromHex to deserialize block header
Browse files Browse the repository at this point in the history
  • Loading branch information
codablock committed Apr 4, 2019
1 parent 9998484 commit 9f2e5d0
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions qa/rpc-tests/dip4-coinbasemerkleroots.py
Original file line number Diff line number Diff line change
Expand Up @@ -109,8 +109,7 @@ def test_getmnlistdiff(self, baseBlockHash, blockHash, baseMNList, expectedDelet

def test_getmnlistdiff_base(self, baseBlockHash, blockHash):
hexstr = self.nodes[0].getblockheader(blockHash, False)
header = CBlockHeader()
header.deserialize(BytesIO(hex_str_to_bytes(hexstr)))
header = FromHex(CBlockHeader(), hexstr)

d = self.test_node.getmnlistdiff(int(baseBlockHash, 16), int(blockHash, 16))
assert_equal(d.baseBlockHash, int(baseBlockHash, 16))
Expand Down

0 comments on commit 9f2e5d0

Please sign in to comment.