|
|
|
@ -33,8 +33,8 @@ defmodule Pleroma.Web.TwitterAPI.UserViewTest do
|
|
|
|
|
{:ok, user} = User.update_follower_count(user)
|
|
|
|
|
Cachex.set(:user_cache, "user_info:#{user.id}", User.user_info(Repo.get!(User, user.id)))
|
|
|
|
|
|
|
|
|
|
image = "http://localhost:4001/static/avi.png"
|
|
|
|
|
banner = "http://localhost:4001/static/banner.png"
|
|
|
|
|
image = "http://localhost:4001/images/avi.png"
|
|
|
|
|
banner = "http://localhost:4001/images/banner.png"
|
|
|
|
|
|
|
|
|
|
represented = %{
|
|
|
|
|
"id" => user.id,
|
|
|
|
@ -65,8 +65,8 @@ defmodule Pleroma.Web.TwitterAPI.UserViewTest do
|
|
|
|
|
test "A user for a given other follower", %{user: user} do
|
|
|
|
|
{:ok, follower} = UserBuilder.insert(%{following: [User.ap_followers(user)]})
|
|
|
|
|
{:ok, user} = User.update_follower_count(user)
|
|
|
|
|
image = "http://localhost:4001/static/avi.png"
|
|
|
|
|
banner = "http://localhost:4001/static/banner.png"
|
|
|
|
|
image = "http://localhost:4001/images/avi.png"
|
|
|
|
|
banner = "http://localhost:4001/images/banner.png"
|
|
|
|
|
|
|
|
|
|
represented = %{
|
|
|
|
|
"id" => user.id,
|
|
|
|
@ -98,8 +98,8 @@ defmodule Pleroma.Web.TwitterAPI.UserViewTest do
|
|
|
|
|
follower = insert(:user)
|
|
|
|
|
{:ok, follower} = User.follow(follower, user)
|
|
|
|
|
{:ok, user} = User.update_follower_count(user)
|
|
|
|
|
image = "http://localhost:4001/static/avi.png"
|
|
|
|
|
banner = "http://localhost:4001/static/banner.png"
|
|
|
|
|
image = "http://localhost:4001/images/avi.png"
|
|
|
|
|
banner = "http://localhost:4001/images/banner.png"
|
|
|
|
|
|
|
|
|
|
represented = %{
|
|
|
|
|
"id" => follower.id,
|
|
|
|
@ -131,8 +131,8 @@ defmodule Pleroma.Web.TwitterAPI.UserViewTest do
|
|
|
|
|
user = insert(:user)
|
|
|
|
|
blocker = insert(:user)
|
|
|
|
|
User.block(blocker, user)
|
|
|
|
|
image = "http://localhost:4001/static/avi.png"
|
|
|
|
|
banner = "http://localhost:4001/static/banner.png"
|
|
|
|
|
image = "http://localhost:4001/images/avi.png"
|
|
|
|
|
banner = "http://localhost:4001/images/banner.png"
|
|
|
|
|
|
|
|
|
|
represented = %{
|
|
|
|
|
"id" => user.id,
|
|
|
|
|