diff options
author | MarcoFalke <*~=`'#}+{/-|&$^_@721217.xyz> | 2023-05-11 14:13:14 +0200 |
---|---|---|
committer | MarcoFalke <*~=`'#}+{/-|&$^_@721217.xyz> | 2023-05-18 09:57:02 +0200 |
commit | fadc8490ab4fdd91aaf446e08108657b304a3ded (patch) | |
tree | a7df3ce8f277953e7eadff48a8c3f1ec83f3fc49 | |
parent | 4e8a7654f623fc0dad933b3d93dc54d8206c605d (diff) | |
download | bitcoin-fadc8490ab4fdd91aaf446e08108657b304a3ded.tar.xz |
test: Split up test_notfound_on_unannounced_tx test case
-rwxr-xr-x | test/functional/p2p_leak_tx.py | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/test/functional/p2p_leak_tx.py b/test/functional/p2p_leak_tx.py index 6283dd89ac..82c8ea0abc 100755 --- a/test/functional/p2p_leak_tx.py +++ b/test/functional/p2p_leak_tx.py @@ -23,16 +23,19 @@ class P2PLeakTxTest(BitcoinTestFramework): self.num_nodes = 1 def run_test(self): - gen_node = self.nodes[0] # The block and tx generating node - miniwallet = MiniWallet(gen_node) + self.gen_node = self.nodes[0] # The block and tx generating node + self.miniwallet = MiniWallet(self.gen_node) + self.test_notfound_on_unannounced_tx() + + def test_notfound_on_unannounced_tx(self): inbound_peer = self.nodes[0].add_p2p_connection(P2PNode()) # An "attacking" inbound peer MAX_REPEATS = 100 self.log.info("Running test up to {} times.".format(MAX_REPEATS)) for i in range(MAX_REPEATS): self.log.info('Run repeat {}'.format(i + 1)) - txid = miniwallet.send_self_transfer(from_node=gen_node)['wtxid'] + txid = self.miniwallet.send_self_transfer(from_node=self.gen_node)["wtxid"] want_tx = msg_getdata() want_tx.inv.append(CInv(t=MSG_TX, h=int(txid, 16))) |