scripted-diff: test: Remove brackets after assert

-BEGIN VERIFY SCRIPT-
sed -i --regexp-extended -e 's/assert ?\((.+)\)(( )*)?(#.*)?$/assert \1\3\3\4/g' $(git grep -l --extended-regexp 'assert ?\(' test)
-END VERIFY SCRIPT-
This commit is contained in:
MarcoFalke
2019-02-19 17:43:44 -05:00
parent fab5a1e0f4
commit fa0e65b772
41 changed files with 273 additions and 273 deletions

View File

@ -56,7 +56,7 @@ def make_utxo(node, amount, confirmed=True, scriptPubKey=CScript([1])):
new_size = len(node.getrawmempool())
# Error out if we have something stuck in the mempool, as this
# would likely be a bug.
assert(new_size < mempool_size)
assert new_size < mempool_size
mempool_size = new_size
return COutPoint(int(txid, 16), 0)
@ -163,8 +163,8 @@ class ReplaceByFeeTest(BitcoinTestFramework):
mempool = self.nodes[0].getrawmempool()
assert (tx1a_txid not in mempool)
assert (tx1b_txid in mempool)
assert tx1a_txid not in mempool
assert tx1b_txid in mempool
assert_equal(tx1b_hex, self.nodes[0].getrawtransaction(tx1b_txid))
@ -211,7 +211,7 @@ class ReplaceByFeeTest(BitcoinTestFramework):
mempool = self.nodes[0].getrawmempool()
for doublespent_txid in chain_txids:
assert(doublespent_txid not in mempool)
assert doublespent_txid not in mempool
def test_doublespend_tree(self):
"""Doublespend of a big tree of transactions"""
@ -236,7 +236,7 @@ class ReplaceByFeeTest(BitcoinTestFramework):
tx.vout = vout
tx_hex = txToHex(tx)
assert(len(tx.serialize()) < 100000)
assert len(tx.serialize()) < 100000
txid = self.nodes[0].sendrawtransaction(tx_hex, True)
yield tx
_total_txs[0] += 1
@ -274,7 +274,7 @@ class ReplaceByFeeTest(BitcoinTestFramework):
for tx in tree_txs:
tx.rehash()
assert (tx.hash not in mempool)
assert tx.hash not in mempool
# Try again, but with more total transactions than the "max txs
# double-spent at once" anti-DoS limit.
@ -529,7 +529,7 @@ class ReplaceByFeeTest(BitcoinTestFramework):
# Now tx1b should be able to replace tx1a
tx1b_txid = self.nodes[0].sendrawtransaction(tx1b_hex, True)
assert(tx1b_txid in self.nodes[0].getrawmempool())
assert tx1b_txid in self.nodes[0].getrawmempool()
# 2. Check that absolute fee checks use modified fee.
tx1_outpoint = make_utxo(self.nodes[0], int(1.1*COIN))
@ -556,7 +556,7 @@ class ReplaceByFeeTest(BitcoinTestFramework):
# tx2b should now be accepted
tx2b_txid = self.nodes[0].sendrawtransaction(tx2b_hex, True)
assert(tx2b_txid in self.nodes[0].getrawmempool())
assert tx2b_txid in self.nodes[0].getrawmempool()
def test_rpc(self):
us0 = self.nodes[0].listunspent()[0]