mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2025-04-20 03:11:35 +02:00
users/model: add test for server actor AP ID
This commit is contained in:
parent
a03133e728
commit
9b63609828
1 changed files with 9 additions and 0 deletions
|
@ -144,6 +144,15 @@ func TestAPActorID(t *testing.T) {
|
|||
}
|
||||
}
|
||||
|
||||
func TestAPActorID_APActorID(t *testing.T) {
|
||||
user := user_model.User{ID: user_model.APActorUserID}
|
||||
url := user.APActorID()
|
||||
expected := "https://try.gitea.io/api/v1/activitypub/actor"
|
||||
if url != expected {
|
||||
t.Errorf("unexpected APActorID for server actor, expected: %q, actual: %q", expected, url)
|
||||
}
|
||||
}
|
||||
|
||||
func TestSearchUsers(t *testing.T) {
|
||||
defer tests.AddFixtures("models/user/fixtures/")()
|
||||
require.NoError(t, unittest.PrepareTestDatabase())
|
||||
|
|
Loading…
Add table
Reference in a new issue