projects
/
akkoma
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
2f5b8fb
)
Assign token that can write to follows
author
Mark Felder
<feld@FreeBSD.org>
Sun, 12 Jan 2020 18:14:09 +0000
(12:14 -0600)
committer
Mark Felder
<feld@FreeBSD.org>
Sun, 12 Jan 2020 18:14:09 +0000
(12:14 -0600)
test/web/twitter_api/remote_follow_controller_test.exs
patch
|
blob
|
history
diff --git
a/test/web/twitter_api/remote_follow_controller_test.exs
b/test/web/twitter_api/remote_follow_controller_test.exs
index dd2f00dfe938a501a6ef581c5872780be611e3e7..4449493759540276d074c1b413ac1c0dc5e1465c 100644
(file)
--- a/
test/web/twitter_api/remote_follow_controller_test.exs
+++ b/
test/web/twitter_api/remote_follow_controller_test.exs
@@
-95,6
+95,7
@@
defmodule Pleroma.Web.TwitterAPI.RemoteFollowControllerTest do
response =
conn
|> assign(:user, user)
+ |> assign(:token, insert(:oauth_token, user: user, scopes: ["write:follows"]))
|> post(remote_follow_path(conn, :do_follow), %{"user" => %{"id" => user2.id}})
|> response(200)
@@
-151,6
+152,7
@@
defmodule Pleroma.Web.TwitterAPI.RemoteFollowControllerTest do
response =
conn
|> assign(:user, refresh_record(user))
+ |> assign(:token, insert(:oauth_token, user: user, scopes: ["write:follows"]))
|> post(remote_follow_path(conn, :do_follow), %{"user" => %{"id" => user2.id}})
|> response(200)