OStatus tests: stop relying on embedded objects
authorrinpatch <rinpatch@sdf.org>
Tue, 6 Aug 2019 21:58:48 +0000 (00:58 +0300)
committerrinpatch <rinpatch@sdf.org>
Tue, 6 Aug 2019 21:58:48 +0000 (00:58 +0300)
test/web/ostatus/ostatus_test.exs

index f8d389020e8fcfa2ce310f792ac982a6f1fea5fd..803a97695bf02d092a870f0320400db1d46e7d6c 100644 (file)
@@ -199,7 +199,7 @@ defmodule Pleroma.Web.OStatusTest do
     assert retweeted_activity.data["type"] == "Create"
     assert retweeted_activity.data["actor"] == user.ap_id
     assert retweeted_activity.local
-    assert retweeted_activity.data["object"]["announcement_count"] == 1
+    assert Object.normalize(retweeted_activity).data["announcement_count"] == 1
   end
 
   test "handle incoming retweets - Mastodon, salmon" do