Skip to content

Commit

Permalink
separate RulesExtra
Browse files Browse the repository at this point in the history
  • Loading branch information
darioush committed Sep 6, 2024
1 parent 0027803 commit 5421d8a
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
4 changes: 4 additions & 0 deletions params/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -661,6 +661,10 @@ type Rules struct {
// Rules for Ethereum releases
EthRules

RulesExtra
}

type RulesExtra struct {
// Rules for Avalanche releases
AvalancheRules

Expand Down
6 changes: 4 additions & 2 deletions plugin/evm/block_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -89,8 +89,10 @@ func TestHandlePrecompileAccept(t *testing.T) {
// Call handlePrecompileAccept
blk := vm.newBlock(ethBlock)
rules := params.Rules{
AccepterPrecompiles: map[common.Address]precompileconfig.Accepter{
precompileAddr: mockAccepter,
RulesExtra: params.RulesExtra{
AccepterPrecompiles: map[common.Address]precompileconfig.Accepter{
precompileAddr: mockAccepter,
},
},
}
require.NoError(blk.handlePrecompileAccept(rules, nil))
Expand Down

0 comments on commit 5421d8a

Please sign in to comment.