ensure we mock_global

This commit is contained in:
Floatingghost 2024-05-22 19:30:03 +01:00
parent 3e1f5e5372
commit 842cac2a50
2 changed files with 1 additions and 10 deletions

View file

@ -9,7 +9,7 @@ defmodule Pleroma.Web.WebFingerTest do
import Tesla.Mock
setup do
mock(fn env -> apply(HttpRequestMock, :request, [env]) end)
mock_global(fn env -> apply(HttpRequestMock, :request, [env]) end)
:ok
end

View file

@ -1464,15 +1464,6 @@ defmodule HttpRequestMock do
}}
end
def get("https://misskey.io/notes/8vs6wxufd0", _, _, _) do
{:ok,
%Tesla.Env{
status: 200,
body: File.read!("test/fixtures/tesla_mock/misskey.io_8vs6wxufd0.json"),
headers: activitypub_object_headers()
}}
end
def get("https://google.com/", _, _, _) do
{:ok, %Tesla.Env{status: 200, body: File.read!("test/fixtures/rich_media/google.html")}}
end