diff options
author | lain <lain@soykaf.club> | 2020-06-06 11:51:10 +0200 |
---|---|---|
committer | lain <lain@soykaf.club> | 2020-06-06 11:51:10 +0200 |
commit | ca0e6e702be3714bb40ff0fb48e9c08aaf322fff (patch) | |
tree | f3c5da9538093235ee531ed2a5f23ae905286daa /test/web/mastodon_api | |
parent | 137adef6e061a1d7d7fc704feac27ebf5319a768 (diff) | |
download | pleroma-ca0e6e702be3714bb40ff0fb48e9c08aaf322fff.tar.gz pleroma-ca0e6e702be3714bb40ff0fb48e9c08aaf322fff.zip |
ChatMessageReference -> Chat.MessageReference
Diffstat (limited to 'test/web/mastodon_api')
-rw-r--r-- | test/web/mastodon_api/views/notification_view_test.exs | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/test/web/mastodon_api/views/notification_view_test.exs b/test/web/mastodon_api/views/notification_view_test.exs index c5691341a..b2fa5b302 100644 --- a/test/web/mastodon_api/views/notification_view_test.exs +++ b/test/web/mastodon_api/views/notification_view_test.exs @@ -7,7 +7,7 @@ defmodule Pleroma.Web.MastodonAPI.NotificationViewTest do alias Pleroma.Activity alias Pleroma.Chat - alias Pleroma.ChatMessageReference + alias Pleroma.Chat.MessageReference alias Pleroma.Notification alias Pleroma.Object alias Pleroma.Repo @@ -17,7 +17,7 @@ defmodule Pleroma.Web.MastodonAPI.NotificationViewTest do alias Pleroma.Web.MastodonAPI.AccountView alias Pleroma.Web.MastodonAPI.NotificationView alias Pleroma.Web.MastodonAPI.StatusView - alias Pleroma.Web.PleromaAPI.ChatMessageReferenceView + alias Pleroma.Web.PleromaAPI.Chat.MessageReferenceView import Pleroma.Factory defp test_notifications_rendering(notifications, user, expected_result) do @@ -45,15 +45,14 @@ defmodule Pleroma.Web.MastodonAPI.NotificationViewTest do object = Object.normalize(activity) chat = Chat.get(recipient.id, user.ap_id) - cm_ref = ChatMessageReference.for_chat_and_object(chat, object) + cm_ref = MessageReference.for_chat_and_object(chat, object) expected = %{ id: to_string(notification.id), pleroma: %{is_seen: false}, type: "pleroma:chat_mention", account: AccountView.render("show.json", %{user: user, for: recipient}), - chat_message: - ChatMessageReferenceView.render("show.json", %{chat_message_reference: cm_ref}), + chat_message: MessageReferenceView.render("show.json", %{chat_message_reference: cm_ref}), created_at: Utils.to_masto_date(notification.inserted_at) } |