chore: update github.com/go-ap/activitypub to 902f6cf (#11301)

Picks the update commit from https://codeberg.org/forgejo/forgejo/pulls/11200 and fixes the new incompatibilities.

I ran full end-to-end tests against Forgejo and basic end-to-end tests against GoToSocial which appear to be working.

Co-authored-by: Renovate Bot <forgejo-renovate-action@forgejo.org>
Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/11301
Reviewed-by: elle <0xllx0@noreply.codeberg.org>
Co-authored-by: famfo <famfo@famfo.xyz>
Co-committed-by: famfo <famfo@famfo.xyz>
This commit is contained in:
famfo 2026-04-02 23:57:13 +02:00 committed by Gusted
parent 4121d5ec85
commit 2fc3144de4
19 changed files with 46 additions and 53 deletions

View file

@ -51,7 +51,7 @@ func Test_LikeMarshalJSON(t *testing.T) {
item: forgefed.ForgeLike{
Activity: ap.Activity{
Actor: ap.IRI("https://repo.prod.meissa.de/api/v1/activitypub/user-id/1"),
Type: "Like",
Type: ap.LikeType,
Object: ap.IRI("https://codeberg.org/api/v1/activitypub/repository-id/1"),
},
},
@ -80,7 +80,7 @@ func Test_LikeUnmarshalJSON(t *testing.T) {
item: []byte(`{"type":"Like","actor":"https://repo.prod.meissa.de/api/activitypub/user-id/1","object":"https://codeberg.org/api/activitypub/repository-id/1"}`),
want: &forgefed.ForgeLike{
Activity: ap.Activity{
Type: "Like",
Type: ap.LikeType,
Actor: ap.IRI("https://repo.prod.meissa.de/api/activitypub/user-id/1"),
Object: ap.IRI("https://codeberg.org/api/activitypub/repository-id/1"),
},
@ -124,7 +124,7 @@ func Test_ForgeLikeValidation(t *testing.T) {
validate := sut.Validate()
assert.Len(t, validate, 2)
assert.Equal(t,
"Field type contains the value , which is not in allowed subset [Like]",
"Field type contains the value <nil>, which is not in allowed subset [Like]",
validate[1])
sut.UnmarshalJSON([]byte(`{"type":"bad-type",