aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorrinpatch <rinpatch@sdf.org>2020-09-05 22:00:51 +0300
committerrinpatch <rinpatch@sdf.org>2020-09-05 22:05:35 +0300
commit170599c390e7c82bdff0d4180d04b2f0f3906f35 (patch)
treebd07bcd17e959bb764d4a5af77df1f96b00ad7e8 /test
parent047a60c46e11b68abfe710a895f4a9c134b951e8 (diff)
downloadpleroma-170599c390e7c82bdff0d4180d04b2f0f3906f35.tar.gz
RichMedia: do not log webpages missing metadata as errors
Also fixes the return value of Parser.parse on errors, previously was just `:ok` due to the logger call in the end
Diffstat (limited to 'test')
-rw-r--r--test/web/rich_media/parser_test.exs4
1 files changed, 1 insertions, 3 deletions
diff --git a/test/web/rich_media/parser_test.exs b/test/web/rich_media/parser_test.exs
index 1e09cbf84..21ae35f8b 100644
--- a/test/web/rich_media/parser_test.exs
+++ b/test/web/rich_media/parser_test.exs
@@ -66,9 +66,7 @@ defmodule Pleroma.Web.RichMedia.ParserTest do
end
test "doesn't just add a title" do
- assert Parser.parse("http://example.com/non-ogp") ==
- {:error,
- "Found metadata was invalid or incomplete: %{\"url\" => \"http://example.com/non-ogp\"}"}
+ assert {:error, {:invalid_metadata, _}} = Parser.parse("http://example.com/non-ogp")
end
test "parses ogp" do