From: github-actions Date: Wed, 28 Sep 2022 13:40:22 +0000 (+0000) Subject: Publish autogenerated nightly docs X-Git-Url: http://internal-gitweb-vhost/script/%22https:/database/scripts/key/enum.ParseCompressedPublicKeyError.html?a=commitdiff_plain;h=d9ca9a4e22707a0e9050356381ebbe29c391b73f;p=bitcoindevkit.org Publish autogenerated nightly docs --- diff --git a/docs/.vuepress/public/docs-rs/bdk/nightly/latest/bdk/wallet/index.html b/docs/.vuepress/public/docs-rs/bdk/nightly/latest/bdk/wallet/index.html index e03e810285..2bffd1d53e 100644 --- a/docs/.vuepress/public/docs-rs/bdk/nightly/latest/bdk/wallet/index.html +++ b/docs/.vuepress/public/docs-rs/bdk/nightly/latest/bdk/wallet/index.html @@ -6,7 +6,7 @@ logo

Module wallet

logo
-

Module bdk::wallet

source · []
Expand description

Wallet

+

Module bdk::wallet

source · []
Expand description

Wallet

This module defines the Wallet structure.

Modules

Address validation callbacks

diff --git a/docs/.vuepress/public/docs-rs/bdk/nightly/latest/src/bdk/wallet/mod.rs.html b/docs/.vuepress/public/docs-rs/bdk/nightly/latest/src/bdk/wallet/mod.rs.html index 48e890a373..9b28c4c692 100644 --- a/docs/.vuepress/public/docs-rs/bdk/nightly/latest/src/bdk/wallet/mod.rs.html +++ b/docs/.vuepress/public/docs-rs/bdk/nightly/latest/src/bdk/wallet/mod.rs.html @@ -5581,6 +5581,22 @@ 5574 5575 5576 +5577 +5578 +5579 +5580 +5581 +5582 +5583 +5584 +5585 +5586 +5587 +5588 +5589 +5590 +5591 +5592
// Bitcoin Dev Kit
 // Written in 2020 by Alekos Filini <alekos.filini@gmail.com>
 //
@@ -7425,7 +7441,7 @@
             .to_string()
             .split_once('#')
             .unwrap()
-            .0
+            .1
             .to_string()
     }
 }
@@ -7521,6 +7537,22 @@
     // OP_PUSH.
     const P2WPKH_FAKE_WITNESS_SIZE: usize = 106;
 
+    #[test]
+    fn test_descriptor_checksum() {
+        let (wallet, _, _) = get_funded_wallet(get_test_wpkh());
+        let checksum = wallet.descriptor_checksum(KeychainKind::External);
+        assert_eq!(checksum.len(), 8);
+
+        let raw_descriptor = wallet
+            .descriptor
+            .to_string()
+            .split_once('#')
+            .unwrap()
+            .0
+            .to_string();
+        assert_eq!(get_checksum(&raw_descriptor).unwrap(), checksum);
+    }
+
     #[test]
     fn test_get_funded_wallet_balance() {
         let (wallet, _, _) = get_funded_wallet(get_test_wpkh());