Skip to content

Commit 447b5f7

Browse files
authored
core: don't modify the shared chainId between tests (#33020)
1 parent 078a5ec commit 447b5f7

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

core/verkle_witness_test.go

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -455,7 +455,7 @@ func verkleTestGenesis(config *params.ChainConfig) *Genesis {
455455
func TestProcessVerkleContractWithEmptyCode(t *testing.T) {
456456
// The test txs were taken from a secondary testnet with chain id 69421
457457
config := *testKaustinenLikeChainConfig
458-
config.ChainID.SetUint64(69421)
458+
config.ChainID = new(big.Int).SetUint64(69421)
459459
gspec := verkleTestGenesis(&config)
460460

461461
genesisH, _, _, _, _, statediffs := GenerateVerkleChainWithGenesis(gspec, beacon.New(ethash.NewFaker()), 1, func(i int, gen *BlockGen) {
@@ -511,7 +511,7 @@ func TestProcessVerkleContractWithEmptyCode(t *testing.T) {
511511
func TestProcessVerkleExtCodeHashOpcode(t *testing.T) {
512512
// The test txs were taken from a secondary testnet with chain id 69421
513513
config := *testKaustinenLikeChainConfig
514-
config.ChainID.SetUint64(69421)
514+
config.ChainID = new(big.Int).SetUint64(69421)
515515

516516
var (
517517
signer = types.LatestSigner(&config)
@@ -615,7 +615,7 @@ func TestProcessVerkleExtCodeHashOpcode(t *testing.T) {
615615
func TestProcessVerkleBalanceOpcode(t *testing.T) {
616616
// The test txs were taken from a secondary testnet with chain id 69421
617617
config := *testKaustinenLikeChainConfig
618-
config.ChainID.SetUint64(69421)
618+
config.ChainID = new(big.Int).SetUint64(69421)
619619

620620
var (
621621
signer = types.LatestSigner(&config)
@@ -672,7 +672,7 @@ func TestProcessVerkleBalanceOpcode(t *testing.T) {
672672
func TestProcessVerkleSelfDestructInSeparateTx(t *testing.T) {
673673
// The test txs were taken from a secondary testnet with chain id 69421
674674
config := *testKaustinenLikeChainConfig
675-
config.ChainID.SetUint64(69421)
675+
config.ChainID = new(big.Int).SetUint64(69421)
676676

677677
var (
678678
signer = types.LatestSigner(&config)
@@ -792,7 +792,7 @@ func TestProcessVerkleSelfDestructInSeparateTx(t *testing.T) {
792792
func TestProcessVerkleSelfDestructInSameTx(t *testing.T) {
793793
// The test txs were taken from a secondary testnet with chain id 69421
794794
config := *testKaustinenLikeChainConfig
795-
config.ChainID.SetUint64(69421)
795+
config.ChainID = new(big.Int).SetUint64(69421)
796796

797797
var (
798798
signer = types.LatestSigner(&config)
@@ -888,7 +888,7 @@ func TestProcessVerkleSelfDestructInSameTx(t *testing.T) {
888888
func TestProcessVerkleSelfDestructInSeparateTxWithSelfBeneficiary(t *testing.T) {
889889
// The test txs were taken from a secondary testnet with chain id 69421
890890
config := *testKaustinenLikeChainConfig
891-
config.ChainID.SetUint64(69421)
891+
config.ChainID = new(big.Int).SetUint64(69421)
892892

893893
var (
894894
signer = types.LatestSigner(&config)
@@ -978,7 +978,7 @@ func TestProcessVerkleSelfDestructInSeparateTxWithSelfBeneficiary(t *testing.T)
978978
func TestProcessVerkleSelfDestructInSameTxWithSelfBeneficiary(t *testing.T) {
979979
// The test txs were taken from a secondary testnet with chain id 69421
980980
config := *testKaustinenLikeChainConfig
981-
config.ChainID.SetUint64(69421)
981+
config.ChainID = new(big.Int).SetUint64(69421)
982982

983983
var (
984984
signer = types.LatestSigner(&config)
@@ -1042,7 +1042,7 @@ func TestProcessVerkleSelfDestructInSameTxWithSelfBeneficiary(t *testing.T) {
10421042
func TestProcessVerkleSelfDestructInSameTxWithSelfBeneficiaryAndPrefundedAccount(t *testing.T) {
10431043
// The test txs were taken from a secondary testnet with chain id 69421
10441044
config := *testKaustinenLikeChainConfig
1045-
config.ChainID.SetUint64(69421)
1045+
config.ChainID = new(big.Int).SetUint64(69421)
10461046

10471047
var (
10481048
signer = types.LatestSigner(&config)

0 commit comments

Comments
 (0)