Skip to content

Commit b861e2d

Browse files
authored
style: prefer formatting prints to mock output instead of writing string (#250)
1 parent 094fde5 commit b861e2d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

internal/config/experiments_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -300,7 +300,7 @@ func Test_Config_GetExperiments(t *testing.T) {
300300
func setupMockPrintDebug() (*bytes.Buffer, func(context.Context, string, ...interface{})) {
301301
mockOutput := &bytes.Buffer{}
302302
mockPrintDebug := func(ctx context.Context, format string, a ...interface{}) {
303-
mockOutput.WriteString(fmt.Sprintf(format, a))
303+
fmt.Fprintf(mockOutput, format, a...)
304304
}
305305
return mockOutput, mockPrintDebug
306306
}

0 commit comments

Comments
 (0)