-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
70535b6 test: Parse witness maps (Christian Lewe) eeddadd feat: Default witness map (Christian Lewe) ef2db67 feat: Generate arbitrary witness maps (Christian Lewe) 5d7a91a feat: Serialize witness map (Christian Lewe) 160b97f feat: Get length of witness map (Christian Lewe) d23acfa doc: the -> a (Christian Lewe) b5b0904 doc: Fix typos (Christian Lewe) Pull request description: Add some methods to make the map of witness values more useful. Test witness serialization in a fuzz test. Fix some docs. ACKs for top commit: apoelstra: ACK 70535b6 successfully ran local tests Tree-SHA512: f843e0708768eb0a1b65d93ced10c74db686f55fccd978f01789bff8a9eb3a6c930498f96f8587c6423965f2f9efec5db528a338d80d4f0d5371d93fbe681715
- Loading branch information
Showing
4 changed files
with
97 additions
and
43 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
#![no_main] | ||
|
||
use libfuzzer_sys::fuzz_target; | ||
|
||
use simfony::witness::WitnessValues; | ||
|
||
fuzz_target!(|witness_values: WitnessValues| { | ||
let witness_text = | ||
serde_json::to_string(&witness_values).expect("Witness map should be convertible into JSON"); | ||
let parsed_witness_text = | ||
serde_json::from_str(&witness_text).expect("Witness JSON should be parseable"); | ||
assert_eq!( | ||
witness_values, parsed_witness_text, | ||
"Witness JSON should parse to original witness map" | ||
); | ||
}); |
Oops, something went wrong.