Skip to content
New issue

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

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

Already on GitHub? # to your account

End to End test #47

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

notTanveer
Copy link
Contributor

This PR adds an end-to-end test for silent payments, ensuring that a crafted transaction sending 5 BTC to a Taproot address (with a 1 BTC fee) is correctly included in the silent block. The test compares the crafted transaction’s txid and output value against the decoded silent block retrieved from the API (/silent-block/height/108). This ensures the transaction was successfully broadcast, mined, and that the correct amount was sent to the intended address.

await bitcoinRPCUtil.mineToAddress(101, initialAddress);

for (const address of p2wkhAddresses) {
await bitcoinRPCUtil.sendToAddress(address, 1);
Copy link
Contributor

Choose a reason for hiding this comment

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

Get the txids from here.

Copy link
Collaborator

Choose a reason for hiding this comment

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

These should be added as dev dependences

Copy link
Collaborator

Choose a reason for hiding this comment

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

this should be under /e2e/helpers. Only application code should be in /src

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants