We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent d3582f2 commit da349f1Copy full SHA for da349f1
test/functional/p2p_disconnect_ban.py
@@ -70,6 +70,15 @@ def run_test(self):
70
self.nodes[1].setmocktime(old_time + 3)
71
assert_equal(len(self.nodes[1].listbanned()), 3)
72
73
+ self.log.info("Test ban_duration and time_remaining")
74
+ for ban in self.nodes[1].listbanned():
75
+ if ban["address"] in ["127.0.0.0/32", "127.0.0.0/24"]:
76
+ assert_equal(ban["ban_duration"], 86400)
77
+ assert_equal(ban["time_remaining"], 86397)
78
+ elif ban["address"] == "2001:4d48:ac57:400:cacf:e9ff:fe1d:9c63/19":
79
+ assert_equal(ban["ban_duration"], 1000)
80
+ assert_equal(ban["time_remaining"], 997)
81
+
82
self.restart_node(1)
83
84
listAfterShutdown = self.nodes[1].listbanned()
0 commit comments