Merge branch 'service-actor-outbox' into 'develop'
ap userview: add outbox field. See merge request pleroma/pleroma!4002
This commit is contained in:
commit
7622a83973
|
@ -0,0 +1 @@
|
|||
ap userview: add outbox field.
|
|
@ -46,6 +46,7 @@ def render("service.json", %{user: user}) do
|
|||
"following" => "#{user.ap_id}/following",
|
||||
"followers" => "#{user.ap_id}/followers",
|
||||
"inbox" => "#{user.ap_id}/inbox",
|
||||
"outbox" => "#{user.ap_id}/outbox",
|
||||
"name" => "Pleroma",
|
||||
"summary" =>
|
||||
"An internal service actor for this Pleroma instance. No user-serviceable parts inside.",
|
||||
|
|
|
@ -76,6 +76,15 @@ test "renders an invisible user with the invisible property set to true" do
|
|||
assert %{"invisible" => true} = UserView.render("service.json", %{user: user})
|
||||
end
|
||||
|
||||
test "service has a few essential fields" do
|
||||
user = insert(:user)
|
||||
result = UserView.render("service.json", %{user: user})
|
||||
assert result["id"]
|
||||
assert result["type"] == "Application"
|
||||
assert result["inbox"]
|
||||
assert result["outbox"]
|
||||
end
|
||||
|
||||
test "renders AKAs" do
|
||||
akas = ["https://i.tusooa.xyz/users/test-pleroma"]
|
||||
user = insert(:user, also_known_as: akas)
|
||||
|
|
Loading…
Reference in New Issue