aboutsummaryrefslogtreecommitdiff
path: root/test/web/twitter_api/twitter_api_test.exs
diff options
context:
space:
mode:
authorRoger Braun <roger@rogerbraun.net>2017-05-10 18:44:57 +0200
committerRoger Braun <roger@rogerbraun.net>2017-05-10 18:44:57 +0200
commit36448d6483c7f53266052e72bd39b04558478410 (patch)
treeb3a7ddfc2520b33a93a6d3bc1cd1915219e92609 /test/web/twitter_api/twitter_api_test.exs
parent2e753e8cd740d540eae7badf5c48197d3914b5f5 (diff)
downloadpleroma-36448d6483c7f53266052e72bd39b04558478410.tar.gz
Add externalprofile to TwAPI.
Diffstat (limited to 'test/web/twitter_api/twitter_api_test.exs')
-rw-r--r--test/web/twitter_api/twitter_api_test.exs9
1 files changed, 9 insertions, 0 deletions
diff --git a/test/web/twitter_api/twitter_api_test.exs b/test/web/twitter_api/twitter_api_test.exs
index fd309e5ed..ebc9e362f 100644
--- a/test/web/twitter_api/twitter_api_test.exs
+++ b/test/web/twitter_api/twitter_api_test.exs
@@ -358,4 +358,13 @@ defmodule Pleroma.Web.TwitterAPI.TwitterAPITest do
assert conversation_id == object.id
end
end
+
+ describe "fetching a user by uri" do
+ test "fetches a user by uri" do
+ user = insert(:user)
+
+ {:ok, represented} = TwitterAPI.get_external_profile(user, user.ap_id)
+ assert represented = UserRepresenter.to_map(user, %{for: user})
+ end
+ end
end