@@ -4,7 +4,7 @@ use std::sync::Arc;
44
55use anyhow:: Context ;
66use assert_matches:: assert_matches;
7- use bdk_chain:: { BlockId , ChainPosition , ConfirmationBlockTime , TxUpdate } ;
7+ use bdk_chain:: { BlockId , ChainPosition , ConfirmationBlockTime } ;
88use bdk_wallet:: coin_selection:: { self , LargestFirstCoinSelection } ;
99use bdk_wallet:: descriptor:: { calc_checksum, DescriptorError , IntoWalletDescriptor } ;
1010use bdk_wallet:: error:: CreateTxError ;
@@ -4254,22 +4254,13 @@ fn test_wallet_transactions_relevant() {
42544254 // add not relevant transaction to test wallet
42554255 let ( other_external_desc, other_internal_desc) = get_test_tr_single_sig_xprv_and_change_desc ( ) ;
42564256 let ( other_wallet, other_txid) = get_funded_wallet ( other_internal_desc, other_external_desc) ;
4257- let other_tx_node = other_wallet. get_tx ( other_txid) . unwrap ( ) . tx_node ;
4258- let other_tx_confirmationblocktime = other_tx_node. anchors . iter ( ) . last ( ) . unwrap ( ) ;
4259- let other_tx_update = TxUpdate {
4260- txs : vec ! [ other_tx_node. tx] ,
4261- txouts : Default :: default ( ) ,
4262- anchors : [ ( * other_tx_confirmationblocktime, other_txid) ] . into ( ) ,
4263- seen_ats : [ ( other_txid, other_tx_confirmationblocktime. confirmation_time ) ] . into ( ) ,
4264- } ;
42654257 let test_wallet_update = Update {
4266- last_active_indices : Default :: default ( ) ,
4267- tx_update : other_tx_update,
4268- chain : None ,
4258+ tx_update : other_wallet. tx_graph ( ) . clone ( ) . into ( ) ,
4259+ ..Default :: default ( )
42694260 } ;
42704261 test_wallet. apply_update ( test_wallet_update) . unwrap ( ) ;
42714262
4272- // verify transaction from other wallet was added but is not it relevant transactions list.
4263+ // verify transaction from other wallet was added but is not in relevant transactions list.
42734264 let relevant_tx_count_after = test_wallet. transactions ( ) . count ( ) ;
42744265 let full_tx_count_after = test_wallet. tx_graph ( ) . full_txs ( ) . count ( ) ;
42754266 let canonical_tx_count_after = test_wallet
0 commit comments