erigon-pulse/cmd/lightclient/clparams/config_test.go
Giulio rebuffo ebe63cfa30
Added tests for config functions and further refactoring (#5646)
Co-authored-by: giuliorebuffo <giuliorebuffo@system76-pc.localdomain>
2022-10-06 18:23:46 +02:00

22 lines
514 B
Go

package clparams
import (
"testing"
"github.com/stretchr/testify/require"
)
func testConfig(t *testing.T, n NetworkType) {
genesis, network, beacon := GetConfigsByNetwork(MainnetNetwork)
require.Equal(t, *genesis, GenesisConfigs[MainnetNetwork])
require.Equal(t, *network, NetworkConfigs[MainnetNetwork])
require.Equal(t, *beacon, BeaconConfigs[MainnetNetwork])
}
func TestGetConfigsByNetwork(t *testing.T) {
testConfig(t, MainnetNetwork)
testConfig(t, SepoliaNetwork)
testConfig(t, GoerliNetwork)
}