(t *testing.T)
| 38 | } |
| 39 | |
| 40 | func TestOnChainUpdate(t *testing.T) { |
| 41 | config := OnChainConfig{} |
| 42 | os.Setenv("CONFIGPATH", "..") |
| 43 | os.Setenv("CHAINNODE", "rinkebyPrivateNode") |
| 44 | config.LoadConfig() |
| 45 | chainConfig := config.GetChainConfig() |
| 46 | chainConfig.DOSAddressBridgeAddress = "0x12345" |
| 47 | config.UpdateConfig(chainConfig) |
| 48 | |
| 49 | config.LoadConfig() |
| 50 | chainConfig = config.GetChainConfig() |
| 51 | actualResult := config.GetChainConfig().DOSAddressBridgeAddress |
| 52 | expectedResult := "0x12345" |
| 53 | |
| 54 | require.Equal(t, expectedResult, actualResult) |
| 55 | } |
nothing calls this directly
no test coverage detected