fix: conform to stricter printf usage in Go 1.24 (#16330)

This commit is contained in:
Mathias Fredriksson
2025-01-29 18:06:22 +02:00
committed by GitHub
parent 967a3810f4
commit 9520da338e
13 changed files with 22 additions and 22 deletions

View File

@ -143,7 +143,7 @@ func TestWebsocketCloseMsg(t *testing.T) {
t.Parallel()
msg := strings.Repeat("d", 255)
trunc := httpapi.WebsocketCloseSprintf(msg)
trunc := httpapi.WebsocketCloseSprintf("%s", msg)
assert.Equal(t, len(trunc), 123)
})
@ -151,7 +151,7 @@ func TestWebsocketCloseMsg(t *testing.T) {
t.Parallel()
msg := strings.Repeat("こんにちは", 10)
trunc := httpapi.WebsocketCloseSprintf(msg)
trunc := httpapi.WebsocketCloseSprintf("%s", msg)
assert.Equal(t, len(trunc), 123)
})
}