Browse Source

[tests] Fix flake8 warnings in getblocktemplate tests

0.15
John Newbery 8 years ago
parent
commit
0a3a5ff454
  1. 9
      test/functional/getblocktemplate_proposals.py

9
test/functional/getblocktemplate_proposals.py

@ -75,7 +75,8 @@ class GetBlockTemplateProposalTest(BitcoinTestFramework): @@ -75,7 +75,8 @@ class GetBlockTemplateProposalTest(BitcoinTestFramework):
def run_test(self):
node = self.nodes[0]
node.generate(1) # Mine a block to leave initial block download
# Mine a block to leave initial block download
node.generate(1)
tmpl = node.getblocktemplate()
if 'coinbasetxn' not in tmpl:
rawcoinbase = encodeUNum(tmpl['height'])
@ -88,12 +89,6 @@ class GetBlockTemplateProposalTest(BitcoinTestFramework): @@ -88,12 +89,6 @@ class GetBlockTemplateProposalTest(BitcoinTestFramework):
# Test 0: Capability advertised
assert('proposal' in tmpl['capabilities'])
# NOTE: This test currently FAILS (regtest mode doesn't enforce block height in coinbase)
## Test 1: Bad height in coinbase
#txlist[0][4+1+36+1+1] += 1
#assert_template(node, tmpl, txlist, 'FIXME')
#txlist[0][4+1+36+1+1] -= 1
# Test 2: Bad input hash for gen tx
txlist[0][4 + 1] += 1
assert_template(node, tmpl, txlist, 'bad-cb-missing')

Loading…
Cancel
Save