We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c06b118 commit 2fb1df5Copy full SHA for 2fb1df5
src/io/utils.rs
@@ -575,3 +575,18 @@ pub(crate) fn read_bdk_wallet_change_set(
575
.map(|indexer| change_set.indexer = indexer);
576
Ok(Some(change_set))
577
}
578
+
579
+#[cfg(test)]
580
+mod tests {
581
+ use super::read_or_generate_seed_file;
582
+ use super::test_utils::random_storage_path;
583
584
+ #[test]
585
+ fn generated_seed_is_readable() {
586
+ let mut rand_path = random_storage_path();
587
+ rand_path.push("test_keys_seed");
588
+ let expected_seed_bytes = read_or_generate_seed_file(&rand_path.to_str().unwrap()).unwrap();
589
+ let read_seed_bytes = read_or_generate_seed_file(&rand_path.to_str().unwrap()).unwrap();
590
+ assert_eq!(expected_seed_bytes, read_seed_bytes);
591
+ }
592
+}
0 commit comments