)
user = insert(:user)
- {:ok, activity1} = CommonAPI.post(user, %{"status" => "yeah #PleromaArt"})
+ {:ok, activity1} = CommonAPI.post(user, %{status: "yeah #PleromaArt"})
object = Object.normalize(activity1)
|> Ecto.Changeset.change(data: object_data)
|> Pleroma.Repo.update()
- {:ok, activity2} = CommonAPI.post(user, %{"status" => "42 This is :moominmamma #PleromaArt"})
+ {:ok, activity2} = CommonAPI.post(user, %{status: "42 This is :moominmamma #PleromaArt"})
- {:ok, _activity3} = CommonAPI.post(user, %{"status" => "This is :moominmamma"})
+ {:ok, _activity3} = CommonAPI.post(user, %{status: "This is :moominmamma"})
response =
conn
end
test "gets a feed (RSS)", %{conn: conn} do
- %{microsecond: {micro, _}} = DateTime.utc_now()
- micro = (micro / 1000) |> floor()
- Process.sleep(950 - micro)
-
Pleroma.Config.put(
[:feed, :post_title],
%{max_length: 25, omission: "..."}
)
user = insert(:user)
- {:ok, activity1} = CommonAPI.post(user, %{"status" => "yeah #PleromaArt"})
+ {:ok, activity1} = CommonAPI.post(user, %{status: "yeah #PleromaArt"})
object = Object.normalize(activity1)
|> Ecto.Changeset.change(data: object_data)
|> Pleroma.Repo.update()
- {:ok, activity2} = CommonAPI.post(user, %{"status" => "42 This is :moominmamma #PleromaArt"})
+ {:ok, activity2} = CommonAPI.post(user, %{status: "42 This is :moominmamma #PleromaArt"})
- {:ok, _activity3} = CommonAPI.post(user, %{"status" => "This is :moominmamma"})
+ {:ok, _activity3} = CommonAPI.post(user, %{status: "This is :moominmamma"})
response =
conn
]
assert xpath(xml, ~x"//channel/item/pubDate/text()"sl) == [
- FeedView.pub_date(activity1.data["published"]),
- FeedView.pub_date(activity2.data["published"])
+ FeedView.pub_date(activity2.data["published"]),
+ FeedView.pub_date(activity1.data["published"])
]
assert xpath(xml, ~x"//channel/item/enclosure/@url"sl) == [