Skip to content

Commit 36d33d3

Browse files
committed
test: use f-strings in feature_cltv.py
1 parent dca173c commit 36d33d3

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

test/functional/feature_cltv.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,7 @@ def run_test(self):
135135
block.nVersion = 3
136136
block.solve()
137137

138-
with self.nodes[0].assert_debug_log(expected_msgs=['{}, bad-version(0x00000003)'.format(block.hash)]):
138+
with self.nodes[0].assert_debug_log(expected_msgs=[f'{block.hash}, bad-version(0x00000003)']):
139139
peer.send_and_ping(msg_block(block))
140140
assert_equal(int(self.nodes[0].getbestblockhash(), 16), tip)
141141
peer.sync_with_ping()
@@ -173,8 +173,7 @@ def run_test(self):
173173
block.hashMerkleRoot = block.calc_merkle_root()
174174
block.solve()
175175

176-
with self.nodes[0].assert_debug_log(expected_msgs=['CheckInputScripts on {} failed with {}'.format(
177-
block.vtx[-1].hash, expected_cltv_reject_reason)]):
176+
with self.nodes[0].assert_debug_log(expected_msgs=[f'CheckInputScripts on {block.vtx[-1].hash} failed with {expected_cltv_reject_reason}']):
178177
peer.send_and_ping(msg_block(block))
179178
assert_equal(int(self.nodes[0].getbestblockhash(), 16), tip)
180179
peer.sync_with_ping()

0 commit comments

Comments
 (0)