aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/web/twitter_api/twitter_api_test.exs9
1 files changed, 7 insertions, 2 deletions
diff --git a/test/web/twitter_api/twitter_api_test.exs b/test/web/twitter_api/twitter_api_test.exs
index 6848413cc..adea67422 100644
--- a/test/web/twitter_api/twitter_api_test.exs
+++ b/test/web/twitter_api/twitter_api_test.exs
@@ -353,10 +353,15 @@ defmodule Pleroma.Web.TwitterAPI.TwitterAPITest do
describe "fetching a user by uri" do
test "fetches a user by uri" do
+ id = "https://mastodon.social/users/lambadalambda"
user = insert(:user)
+ {:ok, represented} = TwitterAPI.get_external_profile(user, id)
+ remote = User.get_by_ap_id(id)
- {:ok, represented} = TwitterAPI.get_external_profile(user, user.ap_id)
- assert represented = UserRepresenter.to_map(user, %{for: user})
+ assert represented == UserRepresenter.to_map(remote, %{for: user})
+
+ # Also fetches the feed.
+ assert Activity.get_create_activity_by_object_ap_id("tag:mastodon.social,2017-04-05:objectId=1641750:objectType=Status")
end
end
end