File tree 1 file changed +18
-0
lines changed
1 file changed +18
-0
lines changed Original file line number Diff line number Diff line change @@ -2056,6 +2056,24 @@ fn test_bump_fee_zero_abs() {
2056
2056
builder. finish ( ) . unwrap ( ) ;
2057
2057
}
2058
2058
2059
+ #[ test]
2060
+ #[ should_panic( expected = "FeeTooLow" ) ]
2061
+ fn test_legacy_bump_fee_zero_abs ( ) {
2062
+ let ( mut wallet, _) = get_funded_wallet ( get_test_pkh ( ) , None ) ;
2063
+ let addr = wallet. next_unused_address ( KeychainKind :: External ) ;
2064
+ let mut builder = wallet. build_tx ( ) ;
2065
+ builder. add_recipient ( addr. script_pubkey ( ) , Amount :: from_sat ( 25_000 ) ) ;
2066
+ let psbt = builder. finish ( ) . unwrap ( ) ;
2067
+
2068
+ let tx = psbt. extract_tx ( ) . expect ( "failed to extract tx" ) ;
2069
+ let txid = tx. compute_txid ( ) ;
2070
+ insert_tx ( & mut wallet, tx) ;
2071
+
2072
+ let mut builder = wallet. build_fee_bump ( txid) . unwrap ( ) ;
2073
+ builder. fee_absolute ( Amount :: ZERO ) ;
2074
+ builder. finish ( ) . unwrap ( ) ;
2075
+ }
2076
+
2059
2077
#[ test]
2060
2078
fn test_bump_fee_reduce_change ( ) {
2061
2079
let ( mut wallet, _) = get_funded_wallet_wpkh ( ) ;
You can’t perform that action at this time.
0 commit comments