mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-22 20:56:42 +00:00
core/txpool/blobpool: fix test post-fusaka
This commit is contained in:
parent
2cf8b8ecc4
commit
7613c416bc
1 changed files with 3 additions and 3 deletions
|
|
@ -992,7 +992,7 @@ func TestOpenCap(t *testing.T) {
|
||||||
storage := t.TempDir()
|
storage := t.TempDir()
|
||||||
|
|
||||||
os.MkdirAll(filepath.Join(storage, pendingTransactionStore), 0700)
|
os.MkdirAll(filepath.Join(storage, pendingTransactionStore), 0700)
|
||||||
store, _ := billy.Open(billy.Options{Path: filepath.Join(storage, pendingTransactionStore)}, newSlotter(testMaxBlobsPerBlock), nil)
|
store, _ := billy.Open(billy.Options{Path: filepath.Join(storage, pendingTransactionStore)}, newSlotterEIP7594(testMaxBlobsPerBlock), nil)
|
||||||
|
|
||||||
// Insert a few transactions from a few accounts
|
// Insert a few transactions from a few accounts
|
||||||
var (
|
var (
|
||||||
|
|
@ -1014,7 +1014,7 @@ func TestOpenCap(t *testing.T) {
|
||||||
|
|
||||||
keep = []common.Address{addr1, addr3}
|
keep = []common.Address{addr1, addr3}
|
||||||
drop = []common.Address{addr2}
|
drop = []common.Address{addr2}
|
||||||
size = uint64(2 * (txAvgSize + blobSize))
|
size = uint64(2 * (txAvgSize + blobSize + uint64(txBlobOverhead)))
|
||||||
)
|
)
|
||||||
store.Put(blob1)
|
store.Put(blob1)
|
||||||
store.Put(blob2)
|
store.Put(blob2)
|
||||||
|
|
@ -1023,7 +1023,7 @@ func TestOpenCap(t *testing.T) {
|
||||||
|
|
||||||
// Verify pool capping twice: first by reducing the data cap, then restarting
|
// Verify pool capping twice: first by reducing the data cap, then restarting
|
||||||
// with a high cap to ensure everything was persisted previously
|
// with a high cap to ensure everything was persisted previously
|
||||||
for _, datacap := range []uint64{2 * (txAvgSize + blobSize), 100 * (txAvgSize + blobSize)} {
|
for _, datacap := range []uint64{2 * (txAvgSize + blobSize + uint64(txBlobOverhead)), 1000 * (txAvgSize + blobSize + uint64(txBlobOverhead))} {
|
||||||
// Create a blob pool out of the pre-seeded data, but cap it to 2 blob transaction
|
// Create a blob pool out of the pre-seeded data, but cap it to 2 blob transaction
|
||||||
statedb, _ := state.New(types.EmptyRootHash, state.NewDatabaseForTesting())
|
statedb, _ := state.New(types.EmptyRootHash, state.NewDatabaseForTesting())
|
||||||
statedb.AddBalance(addr1, uint256.NewInt(1_000_000_000), tracing.BalanceChangeUnspecified)
|
statedb.AddBalance(addr1, uint256.NewInt(1_000_000_000), tracing.BalanceChangeUnspecified)
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue