Merge branch 'bugfix/markdown-newline-codeblocks' into 'develop'
[akkoma] / test / web / twitter_api / views / activity_view_test.exs
index 37444030023aff0921a97762484c337c84d6a245..8b5a16add9b12d30f0cf0be0c067620e01ee469e 100644 (file)
@@ -81,10 +81,13 @@ defmodule Pleroma.Web.TwitterAPI.ActivityViewTest do
 
     result = ActivityView.render("activity.json", activity: activity)
 
-    expected =
+    expected = ":woollysocks: meow"
+
+    expected_html =
       "<img height=\"32px\" width=\"32px\" alt=\"woollysocks\" title=\"woollysocks\" src=\"http://localhost:4001/finmoji/128px/woollysocks-128.png\" /> meow"
 
     assert result["summary"] == expected
+    assert result["summary_html"] == expected_html
   end
 
   test "a create activity with a summary containing invalid HTML" do
@@ -99,6 +102,7 @@ defmodule Pleroma.Web.TwitterAPI.ActivityViewTest do
     expected = "meow"
 
     assert result["summary"] == expected
+    assert result["summary_html"] == expected
   end
 
   test "a create activity with a note" do
@@ -135,6 +139,7 @@ defmodule Pleroma.Web.TwitterAPI.ActivityViewTest do
       "pinned" => false,
       "statusnet_conversation_id" => convo_id,
       "summary" => "",
+      "summary_html" => "",
       "statusnet_html" =>
         "Hey <span><a data-user=\"#{other_user.id}\" href=\"#{other_user.ap_id}\">@<span>shp</span></a></span>!",
       "tags" => [],