diff options
author | MarcoFalke <falke.marco@gmail.com> | 2021-09-20 15:29:20 +0200 |
---|---|---|
committer | MarcoFalke <falke.marco@gmail.com> | 2021-09-20 15:48:47 +0200 |
commit | fafb7b7a892b24405d6b6291d6d72f0e88462f2f (patch) | |
tree | d2ad8e3a081870ee75afe8e68207c91170244c34 /test | |
parent | fa32cb2467056b3fd47f0b88215311faec8fd5a4 (diff) | |
download | bitcoin-fafb7b7a892b24405d6b6291d6d72f0e88462f2f.tar.xz |
test: pep8
Diffstat (limited to 'test')
-rwxr-xr-x | test/functional/mempool_persist.py | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/test/functional/mempool_persist.py b/test/functional/mempool_persist.py index 68daa87e63..b284755b27 100755 --- a/test/functional/mempool_persist.py +++ b/test/functional/mempool_persist.py @@ -100,8 +100,8 @@ class MempoolPersistTest(BitcoinTestFramework): # disconnect nodes & make a txn that remains in the unbroadcast set. self.disconnect_nodes(0, 1) - assert(len(self.nodes[0].getpeerinfo()) == 0) - assert(len(self.nodes[0].p2ps) == 0) + assert_equal(len(self.nodes[0].getpeerinfo()), 0) + assert_equal(len(self.nodes[0].p2ps), 0) self.mini_wallet.send_self_transfer(from_node=self.nodes[0]) self.connect_nodes(0, 2) @@ -178,8 +178,8 @@ class MempoolPersistTest(BitcoinTestFramework): # ensure node0 doesn't have any connections # make a transaction that will remain in the unbroadcast set - assert(len(node0.getpeerinfo()) == 0) - assert(len(node0.p2ps) == 0) + assert_equal(len(node0.getpeerinfo()), 0) + assert_equal(len(node0.p2ps), 0) self.mini_wallet.send_self_transfer(from_node=node0) # shutdown, then startup with wallet disabled @@ -187,8 +187,9 @@ class MempoolPersistTest(BitcoinTestFramework): # check that txn gets broadcast due to unbroadcast logic conn = node0.add_p2p_connection(P2PTxInvStore()) - node0.mockscheduler(16*60) # 15 min + 1 for buffer + node0.mockscheduler(16 * 60) # 15 min + 1 for buffer self.wait_until(lambda: len(conn.get_invs()) == 1) -if __name__ == '__main__': + +if __name__ == "__main__": MempoolPersistTest().main() |