mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-08-17 01:13:45 +00:00
p2p/simulations: fix lint
This commit is contained in:
parent
7690565732
commit
645346739f
2 changed files with 18 additions and 18 deletions
|
|
@ -44,7 +44,7 @@ func LookupMocker(mockerType string) func(net *Network, quit chan struct{}, node
|
||||||
//Useful for frontend to build available mocker selection
|
//Useful for frontend to build available mocker selection
|
||||||
func GetMockerList() []string {
|
func GetMockerList() []string {
|
||||||
list := make([]string, 0, len(mockerList))
|
list := make([]string, 0, len(mockerList))
|
||||||
for k, _ := range mockerList {
|
for k := range mockerList {
|
||||||
list = append(list, k)
|
list = append(list, k)
|
||||||
}
|
}
|
||||||
return list
|
return list
|
||||||
|
|
|
||||||
|
|
@ -53,10 +53,10 @@ func TestMocker(t *testing.T) {
|
||||||
|
|
||||||
//get the list of available mocker types
|
//get the list of available mocker types
|
||||||
resp, err := http.Get(s.URL + "/mocker")
|
resp, err := http.Get(s.URL + "/mocker")
|
||||||
defer resp.Body.Close()
|
|
||||||
if err != nil {
|
if err != nil {
|
||||||
t.Fatalf("Could not get mocker list: %s", err)
|
t.Fatalf("Could not get mocker list: %s", err)
|
||||||
}
|
}
|
||||||
|
defer resp.Body.Close()
|
||||||
|
|
||||||
if resp.StatusCode != 200 {
|
if resp.StatusCode != 200 {
|
||||||
t.Fatalf("Invalid Status Code received, expected 200, got %d", resp.StatusCode)
|
t.Fatalf("Invalid Status Code received, expected 200, got %d", resp.StatusCode)
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue