Skip to content

Move common boilerplate in integration module#348

Merged
DanGould merged 1 commit intopayjoin:masterfrom
spacebear21:integration-boilerplate
Aug 19, 2024
Merged

Move common boilerplate in integration module#348
DanGould merged 1 commit intopayjoin:masterfrom
spacebear21:integration-boilerplate

Conversation

@spacebear21
Copy link
Collaborator

Cut down on duplicate testing fixtures.

@spacebear21 spacebear21 requested a review from DanGould August 16, 2024 15:46
) -> Result<Psbt, BoxError> {
let mut outputs = HashMap::with_capacity(1);
outputs.insert(pj_uri.address.to_string(), pj_uri.amount.unwrap());
debug!("outputs: {:?}", outputs);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This debug! got deleted but that's ok with me

let payjoin_psbt = sender.wallet_process_psbt(&psbt.to_string(), None, None, None)?.psbt;
let payjoin_psbt = sender.finalize_psbt(&payjoin_psbt, Some(false))?.psbt.unwrap();
let payjoin_psbt = Psbt::from_str(&payjoin_psbt)?;
tracing::debug!("Sender's Payjoin PSBT: {:#?}", payjoin_psbt);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we've mixed tracing::debug! and log::debug! in this file which could be unified in a later optimization. No need to stall this huge payoff of tech debt for further optimizations though.

@DanGould DanGould merged commit 2027ee7 into payjoin:master Aug 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

2 participants