Changeset View
Changeset View
Standalone View
Standalone View
test/functional/test_framework/test_framework.py
#!/usr/bin/env python3 | #!/usr/bin/env python3 | ||||
Lint: Code style violation: '/home/nico/bitcoin-abc/test/functional/test_framework/test_framework.py' has code style errors. | |||||
# Copyright (c) 2014-2016 The Bitcoin Core developers | # Copyright (c) 2014-2016 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. | ||||
"""Base class for RPC testing.""" | """Base class for RPC testing.""" | ||||
import argparse | import argparse | ||||
from collections import deque | from collections import deque | ||||
from enum import Enum | from enum import Enum | ||||
▲ Show 20 Lines • Show All 145 Lines • ▼ Show 20 Lines | def main(self): | ||||
print("Testcase failed. Attaching python debugger. Enter ? for help") | print("Testcase failed. Attaching python debugger. Enter ? for help") | ||||
pdb.set_trace() | pdb.set_trace() | ||||
if not self.options.noshutdown: | if not self.options.noshutdown: | ||||
self.log.info("Stopping nodes") | self.log.info("Stopping nodes") | ||||
if self.nodes: | if self.nodes: | ||||
self.stop_nodes() | self.stop_nodes() | ||||
else: | else: | ||||
for node in self.nodes: | |||||
node.cleanup_on_exit = False | |||||
self.log.info( | self.log.info( | ||||
"Note: bitcoinds were not stopped and may still be running") | "Note: bitcoinds were not stopped and may still be running") | ||||
if not self.options.nocleanup and not self.options.noshutdown and success != TestStatus.FAILED: | if not self.options.nocleanup and not self.options.noshutdown and success != TestStatus.FAILED: | ||||
self.log.info("Cleaning up") | self.log.info("Cleaning up") | ||||
shutil.rmtree(self.options.tmpdir) | shutil.rmtree(self.options.tmpdir) | ||||
else: | else: | ||||
self.log.warning( | self.log.warning( | ||||
▲ Show 20 Lines • Show All 349 Lines • Show Last 20 Lines |
'/home/nico/bitcoin-abc/test/functional/test_framework/test_framework.py' has code style errors.