Skip to content

Commit 723a688

Browse files
committed
gssapi: update unit tests to fix govet complaints
1 parent b14311d commit 723a688

File tree

3 files changed

+4
-4
lines changed

3 files changed

+4
-4
lines changed

buffer_test.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ func TestNewBuffer(t *testing.T) {
1717
for a := range []int{allocNone, allocMalloc, allocGSSAPI} {
1818
b, err := l.MakeBuffer(a)
1919
if err != nil {
20-
t.Fatalf("alloc: %v: ", a, err)
20+
t.Fatalf("alloc: %v: %s", a, err)
2121
}
2222
defer b.Release()
2323

@@ -29,7 +29,7 @@ func TestNewBuffer(t *testing.T) {
2929
a, b.Lib, l)
3030
}
3131
if b.C_gss_buffer_t == nil {
32-
t.Fatal("alloc: %v: Got nil buffer, expected non-nil", a)
32+
t.Fatalf("alloc: %v: Got nil buffer, expected non-nil", a)
3333
}
3434
if b.String() != "" {
3535
t.Fatalf(`alloc: %v: String(): got %q, expected ""`,

name_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ func TestNameImportExport(t *testing.T) {
6161
defer kerbOID.Release()
6262

6363
if !mechs.Contains(kerbOID) {
64-
t.Fatalf("Expected %s to be in %s", kerbOID.DebugString, mechs.DebugString)
64+
t.Fatalf("Expected %q to be in %q", kerbOID.DebugString(), mechs.DebugString())
6565
}
6666

6767
makeNames := func(n string) (

test/main_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ type Context struct {
3030
loadonce sync.Once
3131

3232
// Service credentials loaded from keytab
33-
credential *gssapi.CredId `json:"-"`
33+
credential *gssapi.CredId
3434
}
3535

3636
var c = &Context{}

0 commit comments

Comments
 (0)