Skip to content

Commit 9e305e4

Browse files
committed
test: avoid linter warning
Recent golangci-lint warns about shadowing the print function.
1 parent cf39e5e commit 9e305e4

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

test/output.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -559,10 +559,10 @@ func Output(t *testing.T, config OutputConfig) {
559559
t.Run(n, func(t *testing.T) {
560560
initPrintWithKlog(t, test)
561561

562-
testOutput := func(t *testing.T, expectedLine int, print func(buffer *bytes.Buffer)) {
562+
testOutput := func(t *testing.T, expectedLine int, logToBuffer func(buffer *bytes.Buffer)) {
563563
var tmpWriteBuffer bytes.Buffer
564564
klog.SetOutput(&tmpWriteBuffer)
565-
print(&tmpWriteBuffer)
565+
logToBuffer(&tmpWriteBuffer)
566566
klog.Flush()
567567

568568
actual := tmpWriteBuffer.String()

0 commit comments

Comments
 (0)