aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorMartin Zumsande <mzumsande@gmail.com>2023-11-06 16:03:47 -0500
committerMartin Zumsande <mzumsande@gmail.com>2023-11-08 17:34:50 -0500
commit3598a1b5c932634dc7ccb991cc83df5e1a1dcaa9 (patch)
tree70693dd6d84ea9843dd7c6d64406f2d6ee1414ec /test
parent68a90017519874793e34e3b439a63e5aa3a6f6a7 (diff)
downloadbitcoin-3598a1b5c932634dc7ccb991cc83df5e1a1dcaa9.tar.xz
test: enable --v2transport in combination with --usecli
By renaming the "command" send_cli arg. The old name was unsuitable because the "addnode" RPC has its own "command" arg, leading to ambiguity when included in kwargs. Can be tested with "python3 wallet_multiwallet.py --usecli --v2transport" which fails on master because of this (python throws a TypeError).
Diffstat (limited to 'test')
-rwxr-xr-xtest/functional/test_framework/test_node.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/test/functional/test_framework/test_node.py b/test/functional/test_framework/test_node.py
index 435140cbeb..c23119c6cb 100755
--- a/test/functional/test_framework/test_node.py
+++ b/test/functional/test_framework/test_node.py
@@ -787,15 +787,15 @@ class TestNodeCLI():
results.append(dict(error=e))
return results
- def send_cli(self, command=None, *args, **kwargs):
+ def send_cli(self, clicommand=None, *args, **kwargs):
"""Run bitcoin-cli command. Deserializes returned string as python object."""
pos_args = [arg_to_cli(arg) for arg in args]
named_args = [str(key) + "=" + arg_to_cli(value) for (key, value) in kwargs.items()]
p_args = [self.binary, f"-datadir={self.datadir}"] + self.options
if named_args:
p_args += ["-named"]
- if command is not None:
- p_args += [command]
+ if clicommand is not None:
+ p_args += [clicommand]
p_args += pos_args + named_args
self.log.debug("Running bitcoin-cli {}".format(p_args[2:]))
process = subprocess.Popen(p_args, stdin=subprocess.PIPE, stdout=subprocess.PIPE, stderr=subprocess.PIPE, text=True)