diff options
author | Suhas Daftuar <sdaftuar@gmail.com> | 2017-04-03 15:48:55 -0400 |
---|---|---|
committer | Wladimir J. van der Laan <laanwj@gmail.com> | 2017-04-05 08:37:12 +0200 |
commit | d947afc0f7868815dff248ad398c3680def5bf81 (patch) | |
tree | a2350a6e4e4454e1650b93b2735ee64cf1c194a3 | |
parent | 0e5133cb2ef8973951f1b576ead37792f9b37f83 (diff) |
Test prioritisetransaction and ancestor fee state
There is already a similar test for descendant fee state.
Github-Pull: #10144
Rebased-From: ba7dd8bf6f41de647a8df0c4570df6ac20b08e48
-rwxr-xr-x | qa/rpc-tests/mempool_packages.py | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/qa/rpc-tests/mempool_packages.py b/qa/rpc-tests/mempool_packages.py index f605e7524f..f53515d32e 100755 --- a/qa/rpc-tests/mempool_packages.py +++ b/qa/rpc-tests/mempool_packages.py @@ -102,6 +102,18 @@ class MempoolPackagesTest(BitcoinTestFramework): assert_equal(mempool[x], v_descendants[x]) assert(chain[0] not in v_descendants.keys()) + # Check that ancestor modified fees includes fee deltas from + # prioritisetransaction + self.nodes[0].prioritisetransaction(chain[0], 1000) + mempool = self.nodes[0].getrawmempool(True) + ancestor_fees = 0 + for x in chain: + ancestor_fees += mempool[x]['fee'] + assert_equal(mempool[x]['ancestorfees'], ancestor_fees * COIN + 1000) + + # Undo the prioritisetransaction for later tests + self.nodes[0].prioritisetransaction(chain[0], -1000) + # Check that descendant modified fees includes fee deltas from # prioritisetransaction self.nodes[0].prioritisetransaction(chain[-1], 0, 1000) |