diff options
author | lain <lain@soykaf.club> | 2019-06-05 12:06:45 +0200 |
---|---|---|
committer | lain <lain@soykaf.club> | 2019-06-05 12:06:45 +0200 |
commit | 8b9a0dd4a7e60f610e3aa1db92e62bc0fbe54521 (patch) | |
tree | 7123f6083e911a43a0e68ed92db9d53b1789b814 /test/web/twitter_api | |
parent | e4babb1c9ff4c28ff08888736cc330a48b19b396 (diff) | |
download | pleroma-8b9a0dd4a7e60f610e3aa1db92e62bc0fbe54521.tar.gz |
User: Don't error out when following a user that's already followed.
This leads to a few situations where it is impossible to follow a user.
Diffstat (limited to 'test/web/twitter_api')
-rw-r--r-- | test/web/twitter_api/twitter_api_test.exs | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/test/web/twitter_api/twitter_api_test.exs b/test/web/twitter_api/twitter_api_test.exs index d601c8f1f..475531a09 100644 --- a/test/web/twitter_api/twitter_api_test.exs +++ b/test/web/twitter_api/twitter_api_test.exs @@ -116,8 +116,7 @@ defmodule Pleroma.Web.TwitterAPI.TwitterAPITest do {:ok, user, followed, _activity} = TwitterAPI.follow(user, %{"user_id" => followed.id}) assert User.ap_followers(followed) in user.following - {:error, msg} = TwitterAPI.follow(user, %{"user_id" => followed.id}) - assert msg == "Could not follow user: #{followed.nickname} is already on your list." + {:ok, _, _, _} = TwitterAPI.follow(user, %{"user_id" => followed.id}) end test "Follow another user using screen_name" do @@ -132,8 +131,7 @@ defmodule Pleroma.Web.TwitterAPI.TwitterAPITest do followed = User.get_cached_by_ap_id(followed.ap_id) assert followed.info.follower_count == 1 - {:error, msg} = TwitterAPI.follow(user, %{"screen_name" => followed.nickname}) - assert msg == "Could not follow user: #{followed.nickname} is already on your list." + {:ok, _, _, _} = TwitterAPI.follow(user, %{"screen_name" => followed.nickname}) end test "Unfollow another user using user_id" do |