diff --git a/txcache/testutils_test.go b/txcache/testutils_test.go index 165818be..2592a834 100644 --- a/txcache/testutils_test.go +++ b/txcache/testutils_test.go @@ -2,6 +2,7 @@ package txcache import ( "encoding/binary" + "math/big" "math/rand" "sync" "time" @@ -181,6 +182,12 @@ func (wrappedTx *WrappedTransaction) withGasLimit(gasLimit uint64) *WrappedTrans return wrappedTx } +func (wrappedTx *WrappedTransaction) withValue(value *big.Int) *WrappedTransaction { + tx := wrappedTx.Tx.(*transaction.Transaction) + tx.Value = value + return wrappedTx +} + func createFakeSenderAddress(senderTag int) []byte { bytes := make([]byte, 32) binary.LittleEndian.PutUint64(bytes, uint64(senderTag))