diff options
author | Jonathan Schoeller <jonathan.schoeller@rea-group.com> | 2020-06-01 18:05:15 +1000 |
---|---|---|
committer | Jonathan Schoeller <jonathan.schoeller@rea-group.com> | 2020-06-02 06:20:04 +1000 |
commit | d15db4b1fc988736b08c092d000ca1d1ff686975 (patch) | |
tree | 9b223f81d2a0deca3d8082216a00ddb13608d93c /test | |
parent | 091cc4b94e009f7140493cd37798d447c6881e5e (diff) |
refactor: Fix unreachable code in init arg checks
Building with -Wunreachable-code-loop-increment causes a warning
due to always returning on the first iteration of the loop that
outputs errors on invalid args.
Collect all errors, and output them in a single error message
after the loop completes, resolving the warning and avoiding
popup hell by outputting a seperate message for each error.
Diffstat (limited to 'test')
-rwxr-xr-x | test/functional/feature_config_args.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/test/functional/feature_config_args.py b/test/functional/feature_config_args.py index 1a7c656274..a4dc455d57 100755 --- a/test/functional/feature_config_args.py +++ b/test/functional/feature_config_args.py @@ -71,7 +71,7 @@ class ConfArgsTest(BitcoinTestFramework): with open(inc_conf_file2_path, 'w', encoding='utf-8') as conf: conf.write('[testnet]\n') self.restart_node(0) - self.nodes[0].stop_node(expected_stderr='Warning: ' + inc_conf_file_path + ':1 Section [testnot] is not recognized.' + os.linesep + 'Warning: ' + inc_conf_file2_path + ':1 Section [testnet] is not recognized.') + self.nodes[0].stop_node(expected_stderr='Warning: ' + inc_conf_file_path + ':1 Section [testnot] is not recognized.' + os.linesep + inc_conf_file2_path + ':1 Section [testnet] is not recognized.') with open(inc_conf_file_path, 'w', encoding='utf-8') as conf: conf.write('') # clear |