def run_test(self):
    (peer_node, rbf_node) = self.nodes
    rbf_node_address = rbf_node.getnewaddress()
    print('Mining blocks...')
    peer_node.generate(110)
    self.sync_all()
    for i in range(25):
        peer_node.sendtoaddress(rbf_node_address, 0.1)
    self.sync_all()
    peer_node.generate(1)
    self.sync_all()
    assert_equal(rbf_node.getbalance(), Decimal('2.5'))
    print('Running tests')
    dest_address = peer_node.getnewaddress()
    test_small_output_fails(rbf_node, dest_address)
    test_dust_to_fee(rbf_node, dest_address)
    test_simple_bumpfee_succeeds(rbf_node, peer_node, dest_address)
    test_segwit_bumpfee_succeeds(rbf_node, dest_address)
    test_nonrbf_bumpfee_fails(peer_node, dest_address)
    test_notmine_bumpfee_fails(rbf_node, peer_node, dest_address)
    test_bumpfee_with_descendant_fails(rbf_node, rbf_node_address, dest_address)
    test_settxfee(rbf_node, dest_address)
    test_rebumping(rbf_node, dest_address)
    test_rebumping_not_replaceable(rbf_node, dest_address)
    test_unconfirmed_not_spendable(rbf_node, rbf_node_address)
    test_bumpfee_metadata(rbf_node, dest_address)
    test_locked_wallet_fails(rbf_node, dest_address)
    print('Success')
def run_test(self):
    (peer_node, rbf_node) = self.nodes
    rbf_node_address = rbf_node.getnewaddress()
    print('Mining blocks...')
    peer_node.generate(110)
    self.sync_all()
    for i in range(25):
        peer_node.sendtoaddress(rbf_node_address, 0.1)
    self.sync_all()
    peer_node.generate(1)
    self.sync_all()
    assert_equal(rbf_node.getbalance(), Decimal('2.5'))
    print('Running tests')
    dest_address = peer_node.getnewaddress()
    test_small_output_fails(rbf_node, dest_address)
    test_dust_to_fee(rbf_node, dest_address)
    test_simple_bumpfee_succeeds(rbf_node, peer_node, dest_address)
    test_segwit_bumpfee_succeeds(rbf_node, dest_address)
    test_nonrbf_bumpfee_fails(peer_node, dest_address)
    test_notmine_bumpfee_fails(rbf_node, peer_node, dest_address)
    test_bumpfee_with_descendant_fails(rbf_node, rbf_node_address, dest_address)
    test_settxfee(rbf_node, dest_address)
    test_rebumping(rbf_node, dest_address)
    test_rebumping_not_replaceable(rbf_node, dest_address)
    test_unconfirmed_not_spendable(rbf_node, rbf_node_address)
    test_bumpfee_metadata(rbf_node, dest_address)
    test_locked_wallet_fails(rbf_node, dest_address)
    print('Success')