diff --git a/core/blockchain_ext_test.go b/core/blockchain_ext_test.go index 9700614bd4..f85356e9b0 100644 --- a/core/blockchain_ext_test.go +++ b/core/blockchain_ext_test.go @@ -241,7 +241,7 @@ func InsertChainAcceptSingleBlock(t *testing.T, create createFunc) { genesisBalance := big.NewInt(1000000) gspec := &Genesis{ Config: ¶ms.ChainConfig{HomesteadBlock: new(big.Int)}, - Alloc: GenesisAlloc{addr1: {Balance: genesisBalance}}, + Alloc: types.GenesisAlloc{addr1: {Balance: genesisBalance}}, } blockchain, err := create(chainDB, gspec, common.Hash{}, t.TempDir()) if err != nil { @@ -718,7 +718,7 @@ func BuildOnVariousStages(t *testing.T, create createFunc) { genesisBalance := big.NewInt(1000000) gspec := &Genesis{ Config: ¶ms.ChainConfig{HomesteadBlock: new(big.Int)}, - Alloc: GenesisAlloc{ + Alloc: types.GenesisAlloc{ addr1: {Balance: genesisBalance}, addr3: {Balance: genesisBalance}, }, @@ -875,7 +875,7 @@ func EmptyBlocks(t *testing.T, create createFunc) { gspec := &Genesis{ Config: ¶ms.ChainConfig{HomesteadBlock: new(big.Int)}, - Alloc: GenesisAlloc{}, + Alloc: types.GenesisAlloc{}, } blockchain, err := create(chainDB, gspec, common.Hash{}, t.TempDir()) @@ -1396,7 +1396,7 @@ func GenerateChainInvalidBlockFee(t *testing.T, create createFunc) { genesisBalance := new(big.Int).Mul(big.NewInt(1000000), big.NewInt(params.Ether)) gspec := &Genesis{ Config: params.TestFortunaChainConfig, - Alloc: GenesisAlloc{addr1: {Balance: genesisBalance}}, + Alloc: types.GenesisAlloc{addr1: {Balance: genesisBalance}}, } blockchain, err := create(chainDB, gspec, common.Hash{}, t.TempDir()) @@ -1437,7 +1437,7 @@ func InsertChainInvalidBlockFee(t *testing.T, create createFunc) { genesisBalance := new(big.Int).Mul(big.NewInt(1000000), big.NewInt(params.Ether)) gspec := &Genesis{ Config: params.TestFortunaChainConfig, - Alloc: GenesisAlloc{addr1: {Balance: genesisBalance}}, + Alloc: types.GenesisAlloc{addr1: {Balance: genesisBalance}}, } blockchain, err := create(chainDB, gspec, common.Hash{}, t.TempDir()) @@ -1570,7 +1570,7 @@ func StatefulPrecompiles(t *testing.T, create createFunc) { } gspec := &Genesis{ Config: &config, - Alloc: GenesisAlloc{addr1: {Balance: genesisBalance}}, + Alloc: types.GenesisAlloc{addr1: {Balance: genesisBalance}}, } blockchain, err := create(chainDB, gspec, common.Hash{}, t.TempDir()) diff --git a/core/blockchain_log_test.go b/core/blockchain_log_test.go index da2f7d5add..e91411f408 100644 --- a/core/blockchain_log_test.go +++ b/core/blockchain_log_test.go @@ -44,7 +44,7 @@ func TestAcceptedLogsSubscription(t *testing.T) { funds = new(big.Int).Mul(big.NewInt(100), big.NewInt(params.Ether)) gspec = &Genesis{ Config: params.TestChainConfig, - Alloc: GenesisAlloc{addr1: {Balance: funds}}, + Alloc: types.GenesisAlloc{addr1: {Balance: funds}}, BaseFee: big.NewInt(legacy.BaseFee), } contractAddress = crypto.CreateAddress(addr1, 0) diff --git a/core/blockchain_repair_test.go b/core/blockchain_repair_test.go index 244dc9d4e6..ffade5666c 100644 --- a/core/blockchain_repair_test.go +++ b/core/blockchain_repair_test.go @@ -546,7 +546,7 @@ func testRepairWithScheme(t *testing.T, tt *rewindTest, snapshots bool, scheme s gspec = &Genesis{ BaseFee: feeConfig.MinBaseFee, Config: &chainConfig, - Alloc: GenesisAlloc{addr1: {Balance: big.NewInt(params.Ether)}}, + Alloc: types.GenesisAlloc{addr1: {Balance: big.NewInt(params.Ether)}}, } signer = types.LatestSigner(gspec.Config) engine = dummy.NewFullFaker() diff --git a/core/genesis.go b/core/genesis.go index 4e180aebbf..7381a13d85 100644 --- a/core/genesis.go +++ b/core/genesis.go @@ -441,7 +441,7 @@ func (g *Genesis) Verify() error { func GenesisBlockForTesting(db ethdb.Database, addr common.Address, balance *big.Int) *types.Block { g := Genesis{ Config: params.TestChainConfig, - Alloc: GenesisAlloc{addr: {Balance: balance}}, + Alloc: types.GenesisAlloc{addr: {Balance: balance}}, BaseFee: big.NewInt(legacy.BaseFee), } return g.MustCommit(db, triedb.NewDatabase(db, triedb.HashDefaults)) diff --git a/core/state_processor_ext_test.go b/core/state_processor_ext_test.go index d0e3d341a7..5e40a1fa47 100644 --- a/core/state_processor_ext_test.go +++ b/core/state_processor_ext_test.go @@ -60,8 +60,8 @@ func TestBadTxAllowListBlock(t *testing.T) { gspec = &Genesis{ Config: config, - Alloc: GenesisAlloc{ - testAddr: GenesisAccount{ + Alloc: types.GenesisAlloc{ + testAddr: types.Account{ Balance: big.NewInt(1000000000000000000), // 1 ether Nonce: 0, }, diff --git a/core/txindexer_test.go b/core/txindexer_test.go index 1555a1e41a..111efff771 100644 --- a/core/txindexer_test.go +++ b/core/txindexer_test.go @@ -57,7 +57,7 @@ func TestTransactionIndices(t *testing.T) { funds = big.NewInt(10000000000000) gspec = &Genesis{ Config: ¶ms.ChainConfig{HomesteadBlock: new(big.Int)}, - Alloc: GenesisAlloc{addr1: {Balance: funds}}, + Alloc: types.GenesisAlloc{addr1: {Balance: funds}}, } signer = types.LatestSigner(gspec.Config) ) @@ -177,7 +177,7 @@ func TestTransactionSkipIndexing(t *testing.T) { funds = big.NewInt(10000000000000) gspec = &Genesis{ Config: ¶ms.ChainConfig{HomesteadBlock: new(big.Int)}, - Alloc: GenesisAlloc{addr1: {Balance: funds}}, + Alloc: types.GenesisAlloc{addr1: {Balance: funds}}, } signer = types.LatestSigner(gspec.Config) )