From fa0e65b77264476c61832542ab1a9dbedcc738ea Mon Sep 17 00:00:00 2001 From: MarcoFalke Date: Tue, 19 Feb 2019 17:43:44 -0500 Subject: 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- --- test/functional/feature_rbf.py | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'test/functional/feature_rbf.py') diff --git a/test/functional/feature_rbf.py b/test/functional/feature_rbf.py index 274c4922dc..1c8fc438d1 100755 --- a/test/functional/feature_rbf.py +++ b/test/functional/feature_rbf.py @@ -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] -- cgit v1.2.3