test: prep manual equality assert conversions

The later scripted diff only handles plain `assert x == y` lines.
Some remaining tests still use equality inside comprehensions, parenthesized asserts, and other shapes that the line-based rewrite would misread.
Rewrite those sites by hand first so the later mechanical conversion stays safe.
The commit also simplifies the dead `len(["errors"]) == 0` branch in `blocktools.py`, which can never be true.
This commit is contained in:
Lőrinc
2026-03-08 21:22:43 +00:00
parent 4f4516e3f6
commit dcd90fbe54
16 changed files with 49 additions and 34 deletions

View File

@@ -35,7 +35,8 @@ class ToolBitcoinTest(BitcoinTestFramework):
self.add_nodes(self.num_nodes, self.extra_args)
node_argv = self.get_binaries().node_argv()
self.node_options = [node.args[len(node_argv):] for node in self.nodes]
assert all(node.args[:len(node_argv)] == node_argv for node in self.nodes)
for node in self.nodes:
assert_equal(node.args[:len(node_argv)], node_argv)
def set_cmd_args(self, node, args):
"""Set up node so it will be started through bitcoin wrapper command with specified arguments."""