Fixes the p2p_feefilter functional test
@@ -57,25 +57,28 @@ class FeeFilterTest(RavenTestFramework):
NetworkThread().start()
test_node.wait_for_verack()
- # Test that invs are received for all txs at feerate of 70 sat/byte
- node1.settxfee(Decimal("0.00070000"))
+ # Test that invs are received for all txs at feerate of 2,000,000 sats
+ node1.settxfee(Decimal("0.02000000"))
txids = [node1.sendtoaddress(node1.getnewaddress(), 1) for x in range(3)]
assert(allInvsMatch(txids, test_node))
test_node.clear_invs()
- # Set a filter of 60 sat/byte
- test_node.send_and_ping(msg_feefilter(60000))
+ # Set a filter of 1,500,000 sats (must be above 1,000,000 sats (min fee is enforced)
+ test_node.send_and_ping(msg_feefilter(1500000))
# Test that txs are still being received (paying 70 sat/byte)
txids = [node1.sendtoaddress(node1.getnewaddress(), 1) for x in range(3)]
assert(allInvsMatch(txids, test_node))
test_node.clear_invs()
- # Change tx fee rate to 50 sat/byte and test they are no longer received
- node1.settxfee(Decimal("0.00050000"))
+ # Change tx fee rate to 1,350,000 sats and test they are no longer received
+ node1.settxfee(Decimal("0.013500000"))
[node1.sendtoaddress(node1.getnewaddress(), 1) for x in range(3)]
sync_mempools(self.nodes) # must be sure node 0 has received all txs
+ # Raise the tx fee back up above the mintxfee, submit 1 tx on node 0,
+ # then sync nodes 0 and 1 - we should only have 1 tx (this one below since
+ # the one above was below the min txfee).
# Send one transaction from node0 that should be received, so that we
# we can sync the test on receipt (if node1's txs were relayed, they'd
# be received by the time this node0 tx is received). This is
@@ -83,7 +86,7 @@ class FeeFilterTest(RavenTestFramework):
# to 35 entries in an inv, which means that when this next transaction
# is eligible for relay, the prior transactions from node1 are eligible
# as well.
- node0.settxfee(Decimal("0.1000000"))
+ node0.settxfee(Decimal("0.01600000"))
txids = [node0.sendtoaddress(node0.getnewaddress(), 1)] #
assert(allInvsMatch(txids, test_node))
test_node.clear_invs()
