pytest: test new commitment_revocation hook values

This commit is contained in:
Michael Schmoock
2021-09-03 16:30:09 +02:00
committed by Rusty Russell
parent 37a7dab549
commit f6709a7a90
2 changed files with 8 additions and 3 deletions

View File

@@ -6,9 +6,9 @@ plugin = Plugin()
@plugin.hook('commitment_revocation')
def on_commitment_revocation(commitment_txid, penalty_tx, plugin, **kwargs):
def on_commitment_revocation(commitment_txid, penalty_tx, channel_id, commitnum, plugin, **kwargs):
with open('watchtower.csv', 'a') as f:
f.write("{}, {}\n".format(commitment_txid, penalty_tx))
f.write("{}, {}, {}, {}\n".format(commitment_txid, penalty_tx, channel_id, commitnum))
plugin.run()