mirror of
https://github.com/dashpay/dash.git
synced 2024-12-26 04:22:55 +01:00
Use the variable name _ for unused return values
This commit is contained in:
parent
2e6080bbf3
commit
8239794360
@ -213,7 +213,7 @@ class MempoolPackagesTest(BitcoinTestFramework):
|
|||||||
value = send_value
|
value = send_value
|
||||||
|
|
||||||
# Create tx1
|
# Create tx1
|
||||||
(tx1_id, tx1_value) = self.chain_transaction(self.nodes[0], tx0_id, 0, value, fee, 1)
|
tx1_id, _ = self.chain_transaction(self.nodes[0], tx0_id, 0, value, fee, 1)
|
||||||
|
|
||||||
# Create tx2-7
|
# Create tx2-7
|
||||||
vout = 1
|
vout = 1
|
||||||
|
@ -47,16 +47,16 @@ class PreciousTest(BitcoinTestFramework):
|
|||||||
self.log.info("Ensure submitblock can in principle reorg to a competing chain")
|
self.log.info("Ensure submitblock can in principle reorg to a competing chain")
|
||||||
self.nodes[0].generate(1)
|
self.nodes[0].generate(1)
|
||||||
assert_equal(self.nodes[0].getblockcount(), 1)
|
assert_equal(self.nodes[0].getblockcount(), 1)
|
||||||
(hashY, hashZ) = self.nodes[1].generate(2)
|
hashZ = self.nodes[1].generate(2)[-1]
|
||||||
assert_equal(self.nodes[1].getblockcount(), 2)
|
assert_equal(self.nodes[1].getblockcount(), 2)
|
||||||
node_sync_via_rpc(self.nodes[0:3])
|
node_sync_via_rpc(self.nodes[0:3])
|
||||||
assert_equal(self.nodes[0].getbestblockhash(), hashZ)
|
assert_equal(self.nodes[0].getbestblockhash(), hashZ)
|
||||||
|
|
||||||
self.log.info("Mine blocks A-B-C on Node 0")
|
self.log.info("Mine blocks A-B-C on Node 0")
|
||||||
(hashA, hashB, hashC) = self.nodes[0].generate(3)
|
hashC = self.nodes[0].generate(3)[-1]
|
||||||
assert_equal(self.nodes[0].getblockcount(), 5)
|
assert_equal(self.nodes[0].getblockcount(), 5)
|
||||||
self.log.info("Mine competing blocks E-F-G on Node 1")
|
self.log.info("Mine competing blocks E-F-G on Node 1")
|
||||||
(hashE, hashF, hashG) = self.nodes[1].generate(3)
|
hashG = self.nodes[1].generate(3)[-1]
|
||||||
assert_equal(self.nodes[1].getblockcount(), 5)
|
assert_equal(self.nodes[1].getblockcount(), 5)
|
||||||
assert(hashC != hashG)
|
assert(hashC != hashG)
|
||||||
self.log.info("Connect nodes and check no reorg occurs")
|
self.log.info("Connect nodes and check no reorg occurs")
|
||||||
|
@ -91,7 +91,7 @@ class Socks5Connection(object):
|
|||||||
self.conn.sendall(bytearray([0x01, 0x00]))
|
self.conn.sendall(bytearray([0x01, 0x00]))
|
||||||
|
|
||||||
# Read connect request
|
# Read connect request
|
||||||
(ver,cmd,rsv,atyp) = recvall(self.conn, 4)
|
ver, cmd, _, atyp = recvall(self.conn, 4)
|
||||||
if ver != 0x05:
|
if ver != 0x05:
|
||||||
raise IOError('Invalid socks version %i in connect request' % ver)
|
raise IOError('Invalid socks version %i in connect request' % ver)
|
||||||
if cmd != Command.CONNECT:
|
if cmd != Command.CONNECT:
|
||||||
|
@ -101,7 +101,7 @@ class WalletDumpTest(BitcoinTestFramework):
|
|||||||
self.nodes[0].keypoolrefill()
|
self.nodes[0].keypoolrefill()
|
||||||
self.nodes[0].dumpwallet(tmpdir + "/node0/wallet.encrypted.dump")
|
self.nodes[0].dumpwallet(tmpdir + "/node0/wallet.encrypted.dump")
|
||||||
|
|
||||||
found_addr, found_addr_chg, found_addr_rsv, hd_master_addr_enc = \
|
found_addr, found_addr_chg, found_addr_rsv, _ = \
|
||||||
read_dump(tmpdir + "/node0/wallet.encrypted.dump", addrs, hd_master_addr_unenc)
|
read_dump(tmpdir + "/node0/wallet.encrypted.dump", addrs, hd_master_addr_unenc)
|
||||||
assert_equal(found_addr, test_addr_count)
|
assert_equal(found_addr, test_addr_count)
|
||||||
assert_equal(found_addr_chg, 90*2 + 50) # old reserve keys are marked as change now
|
assert_equal(found_addr_chg, 90*2 + 50) # old reserve keys are marked as change now
|
||||||
|
Loading…
Reference in New Issue
Block a user