@@ -596,7 +596,7 @@ func TestFinalizeBlockValidatorUpdates(t *testing.T) {
596
596
mock .Anything ,
597
597
mock .Anything ,
598
598
mock .Anything ).Return (nil )
599
- mp .On ("ReapMaxBytesMaxGas" , mock .Anything , mock .Anything ).Return (types.Txs {})
599
+ mp .On ("ReapMaxBytesMaxGas" , mock .Anything , mock .Anything ).Return ([] * types.CachedTx {})
600
600
601
601
blockStore := store .NewBlockStore (dbm .NewMemDB ())
602
602
blockExec := sm .NewBlockExecutor (
@@ -812,8 +812,9 @@ func TestPrepareProposalReorderTxs(t *testing.T) {
812
812
evpool .On ("PendingEvidence" , mock .Anything ).Return ([]types.Evidence {}, int64 (0 ))
813
813
814
814
txs := test .MakeNTxs (height , 10 )
815
+ cachedTxs := types .CachedTxFromTxs (txs )
815
816
mp := & mpmocks.Mempool {}
816
- mp .On ("ReapMaxBytesMaxGas" , mock .Anything , mock .Anything ).Return (txs )
817
+ mp .On ("ReapMaxBytesMaxGas" , mock .Anything , mock .Anything ).Return (cachedTxs )
817
818
818
819
txs = txs [2 :]
819
820
txs = append (txs [len (txs )/ 2 :], txs [:len (txs )/ 2 ]... )
@@ -871,8 +872,9 @@ func TestPrepareProposalErrorOnTooManyTxs(t *testing.T) {
871
872
var bytesPerTx int64 = 3
872
873
maxDataBytes := types .MaxDataBytes (state .ConsensusParams .Block .MaxBytes , 0 , nValidators )
873
874
txs := test .MakeNTxs (height , maxDataBytes / bytesPerTx + 2 ) // +2 so that tx don't fit
875
+ cachedTxs := types .CachedTxFromTxs (txs )
874
876
mp := & mpmocks.Mempool {}
875
- mp .On ("ReapMaxBytesMaxGas" , mock .Anything , mock .Anything ).Return (txs )
877
+ mp .On ("ReapMaxBytesMaxGas" , mock .Anything , mock .Anything ).Return (cachedTxs )
876
878
877
879
app := & abcimocks.Application {}
878
880
app .On ("PrepareProposal" , mock .Anything , mock .Anything ).Return (& abci.ResponsePrepareProposal {
@@ -928,8 +930,9 @@ func TestPrepareProposalCountSerializationOverhead(t *testing.T) {
928
930
evpool .On ("PendingEvidence" , mock .Anything ).Return ([]types.Evidence {}, int64 (0 ))
929
931
930
932
txs := test .MakeNTxs (height , maxDataBytes / bytesPerTx )
933
+ cachedTxs := types .CachedTxFromTxs (txs )
931
934
mp := & mpmocks.Mempool {}
932
- mp .On ("ReapMaxBytesMaxGas" , mock .Anything , mock .Anything ).Return (txs )
935
+ mp .On ("ReapMaxBytesMaxGas" , mock .Anything , mock .Anything ).Return (cachedTxs )
933
936
934
937
app := & abcimocks.Application {}
935
938
app .On ("PrepareProposal" , mock .Anything , mock .Anything ).Return (& abci.ResponsePrepareProposal {
@@ -977,8 +980,9 @@ func TestPrepareProposalErrorOnPrepareProposalError(t *testing.T) {
977
980
evpool .On ("PendingEvidence" , mock .Anything ).Return ([]types.Evidence {}, int64 (0 ))
978
981
979
982
txs := test .MakeNTxs (height , 10 )
983
+ cachedTxs := types .CachedTxFromTxs (txs )
980
984
mp := & mpmocks.Mempool {}
981
- mp .On ("ReapMaxBytesMaxGas" , mock .Anything , mock .Anything ).Return (txs )
985
+ mp .On ("ReapMaxBytesMaxGas" , mock .Anything , mock .Anything ).Return (cachedTxs )
982
986
983
987
cm := & abciclientmocks.Client {}
984
988
cm .On ("SetLogger" , mock .Anything ).Return ()
@@ -1080,7 +1084,7 @@ func TestCreateProposalAbsentVoteExtensions(t *testing.T) {
1080
1084
mock .Anything ,
1081
1085
mock .Anything ,
1082
1086
mock .Anything ).Return (nil )
1083
- mp .On ("ReapMaxBytesMaxGas" , mock .Anything , mock .Anything ).Return (types.Txs {})
1087
+ mp .On ("ReapMaxBytesMaxGas" , mock .Anything , mock .Anything ).Return ([] * types.CachedTx {})
1084
1088
1085
1089
blockStore := store .NewBlockStore (dbm .NewMemDB ())
1086
1090
blockExec := sm .NewBlockExecutor (
0 commit comments