qa: Use named args in some tests

This commit is contained in:
MarcoFalke
2018-08-29 12:42:46 -04:00
parent b4d3309673
commit fa782a308d
4 changed files with 13 additions and 13 deletions

View File

@@ -42,7 +42,7 @@ class InvalidBlockRequestTest(BitcoinTestFramework):
# Save the coinbase for later
block1 = block
tip = block.sha256
node.p2p.send_blocks_and_test([block1], node, True)
node.p2p.send_blocks_and_test([block1], node, success=True)
self.log.info("Mature the block.")
node.generate(100)
@@ -79,7 +79,7 @@ class InvalidBlockRequestTest(BitcoinTestFramework):
assert_equal(orig_hash, block2.rehash())
assert(block2_orig.vtx != block2.vtx)
node.p2p.send_blocks_and_test([block2], node, False, False, 16, b'bad-txns-duplicate')
node.p2p.send_blocks_and_test([block2], node, success=False, request_block=False, reject_code=16, reject_reason=b'bad-txns-duplicate')
self.log.info("Test very broken block.")
@@ -92,7 +92,7 @@ class InvalidBlockRequestTest(BitcoinTestFramework):
block3.rehash()
block3.solve()
node.p2p.send_blocks_and_test([block3], node, False, False, 16, b'bad-cb-amount')
node.p2p.send_blocks_and_test([block3], node, success=False, request_block=False, reject_code=16, reject_reason=b'bad-cb-amount')
if __name__ == '__main__':
InvalidBlockRequestTest().main()