Fix a couple of issues reported by go-vet
This commit is contained in:
parent
daee43b891
commit
b09f1ab739
|
@ -62,7 +62,7 @@ var tests = []TestRunner{
|
||||||
t.Errorf("Got LookupBool error: '%v', expected none\n", err)
|
t.Errorf("Got LookupBool error: '%v', expected none\n", err)
|
||||||
}
|
}
|
||||||
if !val {
|
if !val {
|
||||||
t.Errorf("Got %b from LookupBool, expected 'false'\n", val)
|
t.Errorf("Got %t from LookupBool, expected 'false'\n", val)
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
// LookupInt32
|
// LookupInt32
|
||||||
|
|
|
@ -108,7 +108,7 @@ func TestObjectOwner(t *testing.T) {
|
||||||
|
|
||||||
func checkShortId(t *testing.T, Id, shortId string) {
|
func checkShortId(t *testing.T, Id, shortId string) {
|
||||||
if len(shortId) < 7 || len(shortId) >= len(Id) {
|
if len(shortId) < 7 || len(shortId) >= len(Id) {
|
||||||
t.Fatal("bad shortId lenght %s", len(shortId))
|
t.Fatalf("bad shortId lenght %d", len(shortId))
|
||||||
}
|
}
|
||||||
|
|
||||||
if !strings.HasPrefix(Id, shortId) {
|
if !strings.HasPrefix(Id, shortId) {
|
||||||
|
|
Loading…
Reference in New Issue