@@ -1649,15 +1649,15 @@ func TestAdd(t *testing.T) {
1649
1649
signed , _ := types .SignNewTx (keys [add .from ], types .LatestSigner (params .MainnetChainConfig ), add .tx )
1650
1650
sidecar , _ := signed .BlobTxSidecar ().ToBlobTxCellSidecar ()
1651
1651
1652
- if err := pool .add (signed .WithoutBlobTxSidecar (), sidecar ); ! errors .Is (err , add .err ) {
1652
+ if err := pool .add (signed .WithoutBlobTxSidecar (), sidecar , signed . Size () ); ! errors .Is (err , add .err ) {
1653
1653
t .Errorf ("test %d, tx %d: adding transaction error mismatch: have %v, want %v" , i , j , err , add .err )
1654
1654
}
1655
1655
if add .err == nil {
1656
1656
size , exist := pool .lookup .sizeOfTx (signed .Hash ())
1657
1657
if ! exist {
1658
1658
t .Errorf ("test %d, tx %d: failed to lookup transaction's size" , i , j )
1659
1659
}
1660
- if size != signed .WithoutBlobTxSidecar (). Size () {
1660
+ if size != signed .Size () {
1661
1661
t .Errorf ("test %d, tx %d: transaction's size mismatches: have %v, want %v" ,
1662
1662
i , j , size , signed .Size ())
1663
1663
}
@@ -2023,7 +2023,7 @@ func benchmarkPoolPending(b *testing.B, datacap uint64) {
2023
2023
}
2024
2024
statedb .AddBalance (addr , uint256 .NewInt (1_000_000_000 ), tracing .BalanceChangeUnspecified )
2025
2025
sidecar , _ := tx .BlobTxSidecar ().ToBlobTxCellSidecar ()
2026
- pool .add (tx .WithoutBlobTxSidecar (), sidecar )
2026
+ pool .add (tx .WithoutBlobTxSidecar (), sidecar , tx . Size () )
2027
2027
}
2028
2028
statedb .Commit (0 , true , false )
2029
2029
defer pool .Close ()
0 commit comments