From 075222525c29dd1f62ccd15fed0a33ef3d7376d4 Mon Sep 17 00:00:00 2001 From: Lain Soykaf Date: Sun, 10 Dec 2023 17:06:13 +0400 Subject: [PATCH] TransmogrifierTest: Capture the log --- test/pleroma/web/activity_pub/transmogrifier_test.exs | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/test/pleroma/web/activity_pub/transmogrifier_test.exs b/test/pleroma/web/activity_pub/transmogrifier_test.exs index 5e58d75db..9c5983347 100644 --- a/test/pleroma/web/activity_pub/transmogrifier_test.exs +++ b/test/pleroma/web/activity_pub/transmogrifier_test.exs @@ -128,10 +128,11 @@ defmodule Pleroma.Web.ActivityPub.TransmogrifierTest do message = File.read!("test/fixtures/fep-e232.json") |> Jason.decode!() - assert {:ok, activity} = Transmogrifier.handle_incoming(message) - - object = Object.normalize(activity) - assert [%{"type" => "Mention"}, %{"type" => "Link"}] = object.data["tag"] + assert capture_log(fn -> + assert {:ok, activity} = Transmogrifier.handle_incoming(message) + object = Object.normalize(activity) + assert [%{"type" => "Mention"}, %{"type" => "Link"}] = object.data["tag"] + end) =~ "Error while fetching" end test "it accepts quote posts" do