diff options
author | Andrew Chow <achow101-github@achow101.com> | 2020-05-25 12:23:26 -0400 |
---|---|---|
committer | Andrew Chow <achow101-github@achow101.com> | 2020-05-25 12:37:53 -0400 |
commit | cdd955e580dff99f3fa440494ed2b348f7f094af (patch) | |
tree | 5b2ab923046218c63dc1ddeb7cfa52d77fd1cd1f /test | |
parent | c87770915b88d195d264b58111c64142b1965cfa (diff) |
Add basic test for bitcoin-wallet salvage
Diffstat (limited to 'test')
-rwxr-xr-x | test/functional/tool_wallet.py | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/test/functional/tool_wallet.py b/test/functional/tool_wallet.py index 039ce7daee..524e1593ba 100755 --- a/test/functional/tool_wallet.py +++ b/test/functional/tool_wallet.py @@ -203,6 +203,14 @@ class ToolWalletTest(BitcoinTestFramework): assert_equal(shasum_after, shasum_before) self.log.debug('Wallet file shasum unchanged\n') + def test_salvage(self): + # TODO: Check salvage actually salvages and doesn't break things. https://github.com/bitcoin/bitcoin/issues/7463 + self.log.info('Check salvage') + self.start_node(0, ['-wallet=salvage']) + self.stop_node(0) + + self.assert_tool_output('', '-wallet=salvage', 'salvage') + def run_test(self): self.wallet_path = os.path.join(self.nodes[0].datadir, self.chain, 'wallets', 'wallet.dat') self.test_invalid_tool_commands_and_args() @@ -211,7 +219,7 @@ class ToolWalletTest(BitcoinTestFramework): self.test_tool_wallet_info_after_transaction() self.test_tool_wallet_create_on_existing_wallet() self.test_getwalletinfo_on_different_wallet() - + self.test_salvage() if __name__ == '__main__': ToolWalletTest().main() |