Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: broadcast withdrawal decision + tests #607

Merged
merged 2 commits into from
Oct 3, 2024

Conversation

cylewitruk
Copy link
Member

Description

The transaction signer wasn't broadcasting its withdrawal decision in handle_pending_withdraw_request(); this PR adds it and adjusts both the deposit + withdrawal tests to verify that it's broadcasted.

Changes

  • Broadcasts a SignerWithdrawalDecision in handle_pending_withdrawal_request().
  • Adds asserts to both deposit and withdrawal tests to ensure that this is done for both.
  • Some renames of withdraw to withdrawal

Testing Information

Nothing special other than what's noted above.

Checklist:

  • I have performed a self-review of my code
  • My changes generate no new warnings
  • New and existing unit tests pass locally with my changes
  • Any dependent changes have been merged and published in downstream modules

@cylewitruk cylewitruk added the sbtc bootstrap signer The sBTC Bootstrap Signer. label Oct 3, 2024
@cylewitruk cylewitruk self-assigned this Oct 3, 2024
.await;

let msg = message::SignerWithdrawalDecision {
request_id: withdrawal_request.request_id,
block_hash: withdrawal_request.block_hash.0,
Copy link
Member Author

Choose a reason for hiding this comment

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

Plz double-check that this message is (1) correct, (2) populated with the correct data

Copy link
Collaborator

@matteojug matteojug left a comment

Choose a reason for hiding this comment

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

Seems reasonable, but better to wait for Daniel to double triple check

Copy link
Contributor

@djordon djordon left a comment

Choose a reason for hiding this comment

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

Looks good 🚢

signer/src/message.rs Show resolved Hide resolved
@cylewitruk cylewitruk merged commit c8425e0 into main Oct 3, 2024
4 checks passed
@cylewitruk cylewitruk deleted the feat/broadcast-withdrawal-decision branch October 3, 2024 16:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
sbtc bootstrap signer The sBTC Bootstrap Signer.
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

3 participants