Rename tgapi request structs

Add MaybeInaccessibleMessage tests and godoc
Update wiki and Bot API docs for the new naming
This commit is contained in:
2026-04-06 16:06:57 +03:00
parent d55f58c092
commit 83bcab6415
40 changed files with 1946 additions and 914 deletions
+2 -6
View File
@@ -9,10 +9,6 @@ import (
"git.scuroneko.dev/scuroneko/slog"
)
func ptr[T any](v T) *T {
return &v
}
type recordingObserver struct {
started []HandlerStartedEvent
finished []HandlerFinishedEvent
@@ -230,7 +226,7 @@ func TestPrepareUpdateCtxContract(t *testing.T) {
CallbackQuery: &tgapi.CallbackQuery{
ID: "cb-2",
From: tgapi.User{ID: 107},
InlineMessageID: ptr("inline-42"),
InlineMessageID: new("inline-42"),
},
},
wantFrom: true,
@@ -907,7 +903,7 @@ func TestHandleCallbackPopulatesInlineTargets(t *testing.T) {
ID: "cb-inline",
Data: data,
From: tgapi.User{ID: 8},
InlineMessageID: ptr("inline-55"),
InlineMessageID: new("inline-55"),
},
})