Handle incoming tags.

This commit is contained in:
Roger Braun 2017-05-18 15:58:18 +02:00
commit beb7b0ef07
3 changed files with 74 additions and 1 deletions

View file

@ -46,6 +46,13 @@ defmodule Pleroma.Web.OStatusTest do
assert activity.data["object"]["attachment"] |> length == 2
end
test "handle incoming notes with tags" do
incoming = File.read!("test/fixtures/ostatus_incoming_post_tag.xml")
{:ok, [activity]} = OStatus.handle_incoming(incoming)
assert activity.data["object"]["tag"] == ["nsfw"]
end
test "handle incoming notes - Mastodon, salmon, reply" do
# It uses the context of the replied to object
Repo.insert!(%Object{