Skip to content

Commit ba7dd8b

Browse files
committed
Test prioritisetransaction and ancestor fee state
There is already a similar test for descendant fee state.
1 parent 471ed00 commit ba7dd8b

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

test/functional/mempool_packages.py

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -101,6 +101,18 @@ def run_test(self):
101101
assert_equal(mempool[x], v_descendants[x])
102102
assert(chain[0] not in v_descendants.keys())
103103

104+
# Check that ancestor modified fees includes fee deltas from
105+
# prioritisetransaction
106+
self.nodes[0].prioritisetransaction(chain[0], 1000)
107+
mempool = self.nodes[0].getrawmempool(True)
108+
ancestor_fees = 0
109+
for x in chain:
110+
ancestor_fees += mempool[x]['fee']
111+
assert_equal(mempool[x]['ancestorfees'], ancestor_fees * COIN + 1000)
112+
113+
# Undo the prioritisetransaction for later tests
114+
self.nodes[0].prioritisetransaction(chain[0], -1000)
115+
104116
# Check that descendant modified fees includes fee deltas from
105117
# prioritisetransaction
106118
self.nodes[0].prioritisetransaction(chain[-1], 1000)

0 commit comments

Comments
 (0)