Skip to content

Commit

Permalink
chore: use buf.String() instead of string(buf.Bytes()) (#608)
Browse files Browse the repository at this point in the history
  • Loading branch information
testwill authored Oct 24, 2023
1 parent c4046fe commit e7034c2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion syslog_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ func TestSyslogWriter_WithCEE(t *testing.T) {
sw := testCEEwriter{&buf}
log := New(SyslogCEEWriter(sw))
log.Info().Str("key", "value").Msg("message string")
got := string(buf.Bytes())
got := buf.String()
want := "@cee:{"
if !strings.HasPrefix(got, want) {
t.Errorf("Bad CEE message start: want %v, got %v", want, got)
Expand Down

0 comments on commit e7034c2

Please sign in to comment.