Skip to content

Commit d22bd54

Browse files
committed
test: passing a non-positive integer value to -peertimeout should throw an error
1 parent bae8a66 commit d22bd54

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

test/functional/p2p_timeouts.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -94,6 +94,11 @@ def run_test(self):
9494
no_version_node.wait_for_disconnect(timeout=1)
9595
no_send_node.wait_for_disconnect(timeout=1)
9696

97+
self.stop_nodes(0)
98+
self.nodes[0].assert_start_raises_init_error(
99+
expected_msg='Error: peertimeout must be a positive integer.',
100+
extra_args=['-peertimeout=0'],
101+
)
97102

98103
if __name__ == '__main__':
99104
TimeoutsTest().main()

0 commit comments

Comments
 (0)