diff options
author | Jorge Timón <jtimon@jtimon.cc> | 2019-08-22 18:17:31 +0200 |
---|---|---|
committer | Jorge Timón <jtimon@jtimon.cc> | 2019-10-26 13:24:39 +0200 |
commit | 1abcecc40c518a98b7d17880657ec0247abdf125 (patch) | |
tree | b78f9540641279b72e2288e278b54ef08c6c2fcb /test/functional/wallet_hd.py | |
parent | be50469217bd775c4305938634c32e5932f47841 (diff) |
Tests: Use self.chain instead of 'regtest' in almost all current tests
Diffstat (limited to 'test/functional/wallet_hd.py')
-rwxr-xr-x | test/functional/wallet_hd.py | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/test/functional/wallet_hd.py b/test/functional/wallet_hd.py index fa5d5a8878..3107d44e9b 100755 --- a/test/functional/wallet_hd.py +++ b/test/functional/wallet_hd.py @@ -67,11 +67,11 @@ class WalletHDTest(BitcoinTestFramework): self.log.info("Restore backup ...") self.stop_node(1) - # we need to delete the complete regtest directory + # we need to delete the complete chain directory # otherwise node1 would auto-recover all funds in flag the keypool keys as used - shutil.rmtree(os.path.join(self.nodes[1].datadir, "regtest", "blocks")) - shutil.rmtree(os.path.join(self.nodes[1].datadir, "regtest", "chainstate")) - shutil.copyfile(os.path.join(self.nodes[1].datadir, "hd.bak"), os.path.join(self.nodes[1].datadir, "regtest", "wallets", "wallet.dat")) + shutil.rmtree(os.path.join(self.nodes[1].datadir, self.chain, "blocks")) + shutil.rmtree(os.path.join(self.nodes[1].datadir, self.chain, "chainstate")) + shutil.copyfile(os.path.join(self.nodes[1].datadir, "hd.bak"), os.path.join(self.nodes[1].datadir, self.chain, "wallets", "wallet.dat")) self.start_node(1) # Assert that derivation is deterministic @@ -92,9 +92,9 @@ class WalletHDTest(BitcoinTestFramework): # Try a RPC based rescan self.stop_node(1) - shutil.rmtree(os.path.join(self.nodes[1].datadir, "regtest", "blocks")) - shutil.rmtree(os.path.join(self.nodes[1].datadir, "regtest", "chainstate")) - shutil.copyfile(os.path.join(self.nodes[1].datadir, "hd.bak"), os.path.join(self.nodes[1].datadir, "regtest", "wallets", "wallet.dat")) + shutil.rmtree(os.path.join(self.nodes[1].datadir, self.chain, "blocks")) + shutil.rmtree(os.path.join(self.nodes[1].datadir, self.chain, "chainstate")) + shutil.copyfile(os.path.join(self.nodes[1].datadir, "hd.bak"), os.path.join(self.nodes[1].datadir, self.chain, "wallets", "wallet.dat")) self.start_node(1, extra_args=self.extra_args[1]) connect_nodes(self.nodes[0], 1) self.sync_all() |