Rename "block cost" to "block weight"

Github-Pull: #8363
Rebased-From: 2c06bae39edfaa9c0855d83377ad8fda09e4fa08
This commit is contained in:
Suhas Daftuar
2016-07-18 13:28:26 -04:00
committed by Wladimir J. van der Laan
parent a07c8a032c
commit fca1a415ce
18 changed files with 69 additions and 69 deletions

View File

@@ -1065,12 +1065,12 @@ class SegWitTest(BitcoinTestFramework):
assert_equal(wit_block.serialize(False), non_wit_block.serialize())
assert_equal(wit_block.serialize(True), block.serialize(True))
# Test size, vsize, cost
# Test size, vsize, weight
rpc_details = self.nodes[0].getblock(block.hash, True)
assert_equal(rpc_details["size"], len(block.serialize(True)))
assert_equal(rpc_details["strippedsize"], len(block.serialize(False)))
cost = 3*len(block.serialize(False)) + len(block.serialize(True))
assert_equal(rpc_details["cost"], cost)
weight = 3*len(block.serialize(False)) + len(block.serialize(True))
assert_equal(rpc_details["weight"], weight)
# Upgraded node should not ask for blocks from unupgraded
block4 = self.build_next_block(nVersion=4)