]> Git Repo - VerusCoin.git/commitdiff
Make variables local
authorEirik Ogilvie-Wigley <[email protected]>
Mon, 14 Jan 2019 21:05:53 +0000 (14:05 -0700)
committerEirik Ogilvie-Wigley <[email protected]>
Thu, 17 Jan 2019 21:58:50 +0000 (14:58 -0700)
qa/rpc-tests/p2p_txexpiringsoon.py
qa/rpc-tests/p2p_txexpiry_dos.py

index 7b63d3873d3d2ef9fffa832a2f9e6aaf7262707f..ff387d4d29174af446073d4f3679d250d8cd829f 100755 (executable)
@@ -46,8 +46,8 @@ class TxExpiringSoonTest(BitcoinTestFramework):
         assert_equal(0, peerinfo[0]["banscore"])
 
         # Mine some blocks so we can spend
-        self.coinbase_blocks = self.nodes[0].generate(200)
-        self.nodeaddress = self.nodes[0].getnewaddress()
+        coinbase_blocks = self.nodes[0].generate(200)
+        node_address = self.nodes[0].getnewaddress()
 
         # Sync nodes 0 and 1
         sync_blocks(self.nodes[:2])
@@ -60,16 +60,16 @@ class TxExpiringSoonTest(BitcoinTestFramework):
 
         # Mininodes send expiring soon transaction in "tx" message to zcashd node
         tx1 = create_transaction(self.nodes[0],
-                                 self.coinbase_blocks[0],
-                                 self.nodeaddress,
+                                 coinbase_blocks[0],
+                                 node_address,
                                  10.0,
                                  203)
         testnode0.send_message(msg_tx(tx1))
 
         # Mininodes send transaction in "tx" message to zcashd node
         tx2 = create_transaction(self.nodes[0],
-                                 self.coinbase_blocks[1],
-                                 self.nodeaddress,
+                                 coinbase_blocks[1],
+                                 node_address,
                                  10.0,
                                  204)
         testnode0.send_message(msg_tx(tx2))
@@ -119,7 +119,7 @@ class TxExpiringSoonTest(BitcoinTestFramework):
             assert_equal(tx2.sha256, incoming_tx.sha256)
 
         # Sync and mine an empty block with node 2, leaving tx in the mempool of node0 and node1
-        for blkhash in self.coinbase_blocks:
+        for blkhash in coinbase_blocks:
             blk = self.nodes[0].getblock(blkhash, 0)
             self.nodes[2].submitblock(blk)
         self.nodes[2].generate(1)
@@ -179,8 +179,8 @@ class TxExpiringSoonTest(BitcoinTestFramework):
 
         # Create a transaction to verify that processing of "getdata" messages is functioning
         tx3 = create_transaction(self.nodes[0],
-                                 self.coinbase_blocks[2],
-                                 self.nodeaddress,
+                                 coinbase_blocks[2],
+                                 node_address,
                                  10.0,
                                  999)
 
index c7b5f3056e0ed1cc1f33fa623cc49245200544c9..7927f9189704895e80cd37b8b119761eb549a250 100755 (executable)
@@ -44,14 +44,14 @@ class TxExpiryDoSTest(BitcoinTestFramework):
         assert_equal(1, versions.count(OVERWINTER_PROTO_VERSION))
         assert_equal(0, peerinfo[0]["banscore"])
 
-        self.coinbase_blocks = self.nodes[0].generate(1)
+        coinbase_blocks = self.nodes[0].generate(1)
         self.nodes[0].generate(100)
-        self.nodeaddress = self.nodes[0].getnewaddress()
+        node_address = self.nodes[0].getnewaddress()
 
         # Mininodes send transaction to zcashd node.
         spendtx = create_transaction(self.nodes[0],
-                                     self.coinbase_blocks[0],
-                                     self.nodeaddress,
+                                     coinbase_blocks[0],
+                                     node_address,
                                      1.0,
                                      101)
         test_node.send_message(msg_tx(spendtx))
This page took 0.036372 seconds and 4 git commands to generate.