From ef0d3114ecd8b0eb7f5ae1b851da1cd956c6398a Mon Sep 17 00:00:00 2001 From: Mark Tyneway Date: Mon, 3 Oct 2022 17:43:48 -0700 Subject: [PATCH] op-chain-ops: add geth test key to dev L2 genesis alloc Adds the test key used in geth's unit tests to the genesis alloc. This makes testing more seamless when using the op-chain-ops tooling --- op-chain-ops/genesis/helpers.go | 2 ++ op-chain-ops/genesis/layer_two_test.go | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/op-chain-ops/genesis/helpers.go b/op-chain-ops/genesis/helpers.go index 036f05b7e2a54..cfa2833e95530 100644 --- a/op-chain-ops/genesis/helpers.go +++ b/op-chain-ops/genesis/helpers.go @@ -57,6 +57,8 @@ var DevAccounts = []common.Address{ common.HexToAddress("0xdF3e18d64BC6A983f673Ab319CCaE4f1a57C7097"), common.HexToAddress("0xde3829a23df1479438622a08a116e8eb3f620bb5"), common.HexToAddress("0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266"), + // Test account used by geth tests + common.HexToAddress("0x71562b71999873DB5b286dF957af199Ec94617F7"), } // The devBalance is the amount of wei that a dev account is funded with. diff --git a/op-chain-ops/genesis/layer_two_test.go b/op-chain-ops/genesis/layer_two_test.go index 4fb4f72d02023..8db45e833113c 100644 --- a/op-chain-ops/genesis/layer_two_test.go +++ b/op-chain-ops/genesis/layer_two_test.go @@ -77,7 +77,7 @@ func TestBuildL2DeveloperGenesis(t *testing.T) { require.Equal(t, adminSlot, proxyAdmin.Address.Hash()) require.Equal(t, account.Code, depB) } - require.Equal(t, 2338, len(gen.Alloc)) + require.Equal(t, 2339, len(gen.Alloc)) if writeFile { file, _ := json.MarshalIndent(gen, "", " ")