From bc1c3e6337ec79063d97650913d59379d66db75a Mon Sep 17 00:00:00 2001 From: Ivan Danyliuk Date: Fri, 9 Feb 2018 22:55:05 +0200 Subject: [PATCH] Make linters happy --- geth/api/connection.go | 5 +++-- geth/api/connection_test.go | 6 +++--- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/geth/api/connection.go b/geth/api/connection.go index 9e3b7d751..fcc53317a 100644 --- a/geth/api/connection.go +++ b/geth/api/connection.go @@ -34,9 +34,10 @@ func NewConnectionType(s string) ConnectionType { return ConnectionUnknown } +// ConnectionType constants const ( - ConnectionCellular = iota // default value, LTE, 4G, 3G, EDGE, etc. - ConnectionWifi // WIFI or iOS simulator + ConnectionCellular ConnectionType = iota // default value, LTE, 4G, 3G, EDGE, etc. + ConnectionWifi // WIFI or iOS simulator ConnectionUnknown ) diff --git a/geth/api/connection_test.go b/geth/api/connection_test.go index 00e43105f..76d23786e 100644 --- a/geth/api/connection_test.go +++ b/geth/api/connection_test.go @@ -5,15 +5,15 @@ import "testing" func TestConnectionType(t *testing.T) { c := NewConnectionType("wifi") if c != ConnectionWifi { - t.Fatalf("Wrong connection type: %s", c) + t.Fatalf("Wrong connection type: %v", c) } c = NewConnectionType("cellular") if c != ConnectionCellular { - t.Fatalf("Wrong connection type: %s", c) + t.Fatalf("Wrong connection type: %v", c) } c = NewConnectionType("bluetooth") if c != ConnectionUnknown { - t.Fatalf("Wrong connection type: %s", c) + t.Fatalf("Wrong connection type: %v", c) } }