mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-06-03 17:54:19 +02:00
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:
@@ -114,7 +114,7 @@ class AcceptBlockTest(BitcoinTestFramework):
|
||||
if x['hash'] == block_h1f.hash:
|
||||
assert_equal(x['status'], "headers-only")
|
||||
tip_entry_found = True
|
||||
assert(tip_entry_found)
|
||||
assert tip_entry_found
|
||||
assert_raises_rpc_error(-1, "Block not found on disk", self.nodes[0].getblock, block_h1f.hash)
|
||||
|
||||
# 4. Send another two block that build on the fork.
|
||||
@@ -131,7 +131,7 @@ class AcceptBlockTest(BitcoinTestFramework):
|
||||
if x['hash'] == block_h2f.hash:
|
||||
assert_equal(x['status'], "headers-only")
|
||||
tip_entry_found = True
|
||||
assert(tip_entry_found)
|
||||
assert tip_entry_found
|
||||
|
||||
# But this block should be accepted by node since it has equal work.
|
||||
self.nodes[0].getblock(block_h2f.hash)
|
||||
@@ -150,7 +150,7 @@ class AcceptBlockTest(BitcoinTestFramework):
|
||||
if x['hash'] == block_h3.hash:
|
||||
assert_equal(x['status'], "headers-only")
|
||||
tip_entry_found = True
|
||||
assert(tip_entry_found)
|
||||
assert tip_entry_found
|
||||
self.nodes[0].getblock(block_h3.hash)
|
||||
|
||||
# But this block should be accepted by node since it has more work.
|
||||
@@ -263,7 +263,7 @@ class AcceptBlockTest(BitcoinTestFramework):
|
||||
if x['hash'] == block_292.hash:
|
||||
assert_equal(x['status'], "headers-only")
|
||||
tip_entry_found = True
|
||||
assert(tip_entry_found)
|
||||
assert tip_entry_found
|
||||
assert_raises_rpc_error(-1, "Block not found on disk", self.nodes[0].getblock, block_292.hash)
|
||||
|
||||
test_node.send_message(msg_block(block_289f))
|
||||
|
||||
Reference in New Issue
Block a user