Basic peertube support.

This commit is contained in:
Haelwenn (lanodan) Monnier 2018-07-12 19:06:28 +02:00
commit 74c74decf5
No known key found for this signature in database
GPG key ID: D5B7A8E43C997DEE
8 changed files with 59 additions and 10 deletions

View file

@ -760,6 +760,22 @@ defmodule HTTPoisonMock do
}}
end
def get("https://peertube.moe/videos/watch/df5f464b-be8d-46fb-ad81-2d4c2d1630e3", _, _) do
{:ok,
%Response{
status_code: 200,
body: File.read!("test/fixtures/httpoison_mock/peertube.moe-vid.json")
}}
end
def get("https://peertube.moe/accounts/7even", _, _) do
{:ok,
%Response{
status_code: 200,
body: File.read!("test/fixtures/httpoison_mock/7even.json")
}}
end
def get(url, body, headers) do
{:error,
"Not implemented the mock response for get #{inspect(url)}, #{inspect(body)}, #{