Commit cf52332c authored by Mark Tyneway's avatar Mark Tyneway

op-e2e: last receipt getter

Add a getter for fetching the last receipt. This
is useful if values from a receipt need to be parsed
as input to additional calls
parent 39e1d598
......@@ -196,6 +196,13 @@ func (s *BasicUser[B]) TxValue() *big.Int {
return big.NewInt(0)
}
func (s *BasicUser[B]) LastTxReceipt(t Testing) *types.Receipt {
require.NotEqual(t, s.lastTxHash, common.Hash{}, "must send tx before getting last receipt")
receipt, err := s.env.EthCl.TransactionReceipt(t.Ctx(), s.lastTxHash)
require.NoError(t, err)
return receipt
}
// ActMakeTx makes a tx with the predetermined contents (see randomization and other actions)
// and sends it to the tx pool
func (s *BasicUser[B]) ActMakeTx(t Testing) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment