Skip to content

Conversation

110CodingP
Copy link

@110CodingP 110CodingP commented Aug 19, 2025

Description

Added some basic functions to test WalletPersister impl. Fixes #14 and might help with #234 .

Changelog notice

Added
    - functions to test `WalletPersister` impl of custom persistence backends.
    - tests for file_store and rusqlite based on persistence testing functions added

Checklists

All Submissions:

New Features:

  • I've added tests for the new feature
  • I've added docs for the new feature

Added the following functions:-
  - `persist_wallet_changeset`: tests if each field of wallet ChangeSet
  is persisted.
  - `persist_multiple_wallet_changesets`: tests if multiple wallets can
  be persisted in a single file.
  - `persist_network`: tests if network is persisted
  - `persist_keychains`: tests if descriptors are persisted
  - `persist_single_keychain`: tests if descriptor in single keychain
  wallet is persisted.
Used persist_test_utils to test WalletPersister impl of file_store and
rusqlite.
@110CodingP 110CodingP force-pushed the add_persist_test_utils branch from 621ad7b to abcf868 Compare August 23, 2025 13:35
@coveralls
Copy link

Pull Request Test Coverage Report for Build 17176091820

Details

  • 214 of 256 (83.59%) changed or added relevant lines in 1 file are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage decreased (-0.04%) to 84.871%

Changes Missing Coverage Covered Lines Changed/Added Lines %
wallet/src/persist_test_utils.rs 214 256 83.59%
Totals Coverage Status
Change from base Build 17132535147: -0.04%
Covered Lines: 6883
Relevant Lines: 8110

💛 - Coveralls

@ValuedMammal ValuedMammal moved this from In Progress to Needs Review in BDK Wallet Aug 24, 2025
@ValuedMammal
Copy link
Collaborator

Looks good overall. I haven't noticed any issues 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Needs Review
Development

Successfully merging this pull request may close these issues.

Persister test suite for testing redb persister
3 participants