itests: Fix TestEthFilterAPIDisabledViaConfig

This commit is contained in:
Łukasz Magiera
2023-02-02 15:59:55 +01:00
parent fe1e0974cb
commit 8ce0b984b7
4 changed files with 66 additions and 21 deletions
+8 -4
View File
@@ -261,10 +261,14 @@ func ConfigFullNode(c interface{}) Option {
// in lite-mode Eth api is provided by gateway
ApplyIf(isFullNode,
Override(new(full.EthEventAPI), modules.EthEventAPI(cfg.Fevm)),
If(cfg.Fevm.EnableEthRPC, Override(new(full.EthModuleAPI), modules.EthModuleAPI(cfg.Fevm))),
If(!cfg.Fevm.EnableEthRPC, Override(new(full.EthModuleAPI), &full.EthModuleDummy{})),
If(cfg.Fevm.EnableEthRPC,
Override(new(full.EthModuleAPI), modules.EthModuleAPI(cfg.Fevm)),
Override(new(full.EthEventAPI), modules.EthEventAPI(cfg.Fevm)),
),
If(!cfg.Fevm.EnableEthRPC,
Override(new(full.EthModuleAPI), &full.EthModuleDummy{}),
Override(new(full.EthEventAPI), &full.EthModuleDummy{}),
),
),
)
}