Changeset View
Changeset View
Standalone View
Standalone View
test/functional/feature_abortnode.py
#!/usr/bin/env python3 | #!/usr/bin/env python3 | ||||
# Copyright (c) 2019 The Bitcoin Core developers | # Copyright (c) 2019 The Bitcoin Core developers | ||||
# Distributed under the MIT software license, see the accompanying | # Distributed under the MIT software license, see the accompanying | ||||
# file COPYING or http://www.opensource.org/licenses/mit-license.php. | # file COPYING or http://www.opensource.org/licenses/mit-license.php. | ||||
"""Test bitcoind aborts if can't disconnect a block. | """Test bitcoind aborts if can't disconnect a block. | ||||
- Start a single node and generate 3 blocks. | - Start a single node and generate 3 blocks. | ||||
- Delete the undo data. | - Delete the undo data. | ||||
- Mine a fork that requires disconnecting the tip. | - Mine a fork that requires disconnecting the tip. | ||||
- Verify that bitcoind AbortNode's. | - Verify that bitcoind AbortNode's. | ||||
""" | """ | ||||
from test_framework.test_framework import BitcoinTestFramework | |||||
from test_framework.util import get_datadir_path, connect_nodes | |||||
import os | import os | ||||
from test_framework.test_framework import BitcoinTestFramework | |||||
from test_framework.util import connect_nodes, get_datadir_path | |||||
class AbortNodeTest(BitcoinTestFramework): | class AbortNodeTest(BitcoinTestFramework): | ||||
def set_test_params(self): | def set_test_params(self): | ||||
self.setup_clean_chain = True | self.setup_clean_chain = True | ||||
self.num_nodes = 2 | self.num_nodes = 2 | ||||
self.extra_args = [["-noparkdeepreorg"], []] | self.extra_args = [["-noparkdeepreorg"], []] | ||||
Show All 27 Lines |