Fix Shelley genesis parsing#577
Merged
Merged
Conversation
SebastienGllmt
commented
Jan 14, 2025
Comment on lines
+236
to
+253
| #[test] | ||
| fn calc_address_txid() { | ||
| let config = load_test_data_config("golden"); | ||
| let utxos = shelley_utxos(&config); | ||
| let utxo = utxos.first().unwrap(); | ||
| assert_eq!( | ||
| utxo.0.to_string(), | ||
| "f9ec23569778d1c5f7f43e0e98464335f02fb98b57683faa1c6b18c82921d2da" | ||
| ); | ||
| assert_eq!( | ||
| utxo.1.to_bech32().unwrap(), | ||
| "addr_test1qrsm4h32h9r95f8at64ykuugxqu3wvu0s5ay3vg6tlyevjh4e2flkegka00r69gt8c4vkxgf2vnnph3nsvhlkg5ukgxslee3tf" | ||
| ); | ||
| assert_eq!( | ||
| utxo.2, | ||
| 12157196 | ||
| ); | ||
| } |
Contributor
Author
There was a problem hiding this comment.
I also tested this gives the same UTXO as running a yaci-devkit local node with this genesis config👍
4 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This fixes the Shelley part of #296
Notably,
poolsinitial_fundsAdditionally, this PR adds a new
shelley_utxoshelper function to help unblock this Dolos issue: txpipe/dolos#427Background
This PR introduces a new "golden" test, which is taken from the Haskell codebase here
Notably, you can find the original code for this serialization logic in the Haskell codebase at the following: