diff options
author | Alex Gleason <alex@alexgleason.me> | 2021-04-29 12:19:10 -0500 |
---|---|---|
committer | Alex Gleason <alex@alexgleason.me> | 2021-04-29 12:19:10 -0500 |
commit | e7ac15905e04ba33b0dd0ed32ab42cdea5dab8f9 (patch) | |
tree | 5cc9585793e2e020d75f90b99ebb91a71d56ee6b /test/support/http_request_mock.ex | |
parent | b6a69b5efda5f75ad716252c69ae658a4e885b0a (diff) | |
parent | 115673bce773f91630c3bd4fd2d0023f92bee163 (diff) | |
download | pleroma-e7ac15905e04ba33b0dd0ed32ab42cdea5dab8f9.tar.gz pleroma-e7ac15905e04ba33b0dd0ed32ab42cdea5dab8f9.zip |
Merge remote-tracking branch 'upstream/develop' into oauth-token-id
Diffstat (limited to 'test/support/http_request_mock.ex')
-rw-r--r-- | test/support/http_request_mock.ex | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/test/support/http_request_mock.ex b/test/support/http_request_mock.ex index eb692fab5..8807c2d14 100644 --- a/test/support/http_request_mock.ex +++ b/test/support/http_request_mock.ex @@ -89,6 +89,18 @@ defmodule HttpRequestMock do }} end + def get("https://mastodon.sdf.org/users/rinpatch/collections/featured", _, _, _) do + {:ok, + %Tesla.Env{ + status: 200, + body: + File.read!("test/fixtures/users_mock/masto_featured.json") + |> String.replace("{{domain}}", "mastodon.sdf.org") + |> String.replace("{{nickname}}", "rinpatch"), + headers: [{"content-type", "application/activity+json"}] + }} + end + def get("https://patch.cx/objects/tesla_mock/poll_attachment", _, _, _) do {:ok, %Tesla.Env{ @@ -905,6 +917,18 @@ defmodule HttpRequestMock do }} end + def get("https://mastodon.social/users/lambadalambda/collections/featured", _, _, _) do + {:ok, + %Tesla.Env{ + status: 200, + body: + File.read!("test/fixtures/users_mock/masto_featured.json") + |> String.replace("{{domain}}", "mastodon.social") + |> String.replace("{{nickname}}", "lambadalambda"), + headers: activitypub_object_headers() + }} + end + def get("https://apfed.club/channel/indio", _, _, _) do {:ok, %Tesla.Env{ |