test: ensure reason is checked for invalid blocks rejection

This commit is contained in:
Greg Sanders
2025-05-22 10:43:44 -04:00
parent 1a689a2c88
commit 8fcd684505
2 changed files with 6 additions and 0 deletions

View File

@@ -161,6 +161,8 @@ class FullBlockTest(BitcoinTestFramework):
if template.valid_in_block:
continue
assert template.block_reject_reason or template.reject_reason
self.log.info(f"Reject block with invalid tx: {TxTemplate.__name__}")
blockname = f"for_invalid.{TxTemplate.__name__}"
self.next_block(blockname)