aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorJamesC <james.chiangwu@gmail.com>2019-10-31 12:01:58 +0100
committerJames Chiang <james.chiangwu@gmail.com>2019-11-03 20:34:49 +0100
commit5155602a636c323424f75272ccec38588b3d71cd (patch)
tree1307f6e785c0da16d861709364553a132f41b609 /test
parent2ab01462f48b2d4e0d03ba842c3af8851c67c6f1 (diff)
downloadbitcoin-5155602a636c323424f75272ccec38588b3d71cd.tar.xz
Move argparse() to init()
This ensures TestFramework default parameters are set before setup is called. A child class will therefore have access to defaults when overriding setup.
Diffstat (limited to 'test')
-rwxr-xr-xtest/functional/test_framework/test_framework.py3
1 files changed, 1 insertions, 2 deletions
diff --git a/test/functional/test_framework/test_framework.py b/test/functional/test_framework/test_framework.py
index 7375ab1fb7..c56c0d06ff 100755
--- a/test/functional/test_framework/test_framework.py
+++ b/test/functional/test_framework/test_framework.py
@@ -99,14 +99,13 @@ class BitcoinTestFramework(metaclass=BitcoinTestMetaClass):
self.supports_cli = False
self.bind_to_localhost_only = True
self.set_test_params()
+ self.parse_args()
def main(self):
"""Main function. This should not be overridden by the subclass test scripts."""
assert hasattr(self, "num_nodes"), "Test must set self.num_nodes in set_test_params()"
- self.parse_args()
-
try:
self.setup()
self.run_test()