CI: Bump lint stage to elixir-1.12
[akkoma] / test / pleroma / web / mastodon_api / update_credentials_test.exs
index e3e437a19c538e105c57f9314d8d9b8c08f18cad..1d20278998923323feec3335e0c7e95722b4b870 100644 (file)
@@ -1,5 +1,5 @@
 # Pleroma: A lightweight social networking server
-# Copyright © 2017-2020 Pleroma Authors <https://pleroma.social/>
+# Copyright © 2017-2021 Pleroma Authors <https://pleroma.social/>
 # SPDX-License-Identifier: AGPL-3.0-only
 
 defmodule Pleroma.Web.MastodonAPI.UpdateCredentialsTest do
@@ -35,8 +35,8 @@ defmodule Pleroma.Web.MastodonAPI.UpdateCredentialsTest do
         |> assign(:user, user)
         |> patch("/api/v1/accounts/update_credentials", %{
           "pleroma_settings_store" => %{
-            masto_fe: %{
-              theme: "bla"
+            soapbox_fe: %{
+              themeMode: "bla"
             }
           }
         })
@@ -46,7 +46,7 @@ defmodule Pleroma.Web.MastodonAPI.UpdateCredentialsTest do
       assert user_data["pleroma"]["settings_store"] ==
                %{
                  "pleroma_fe" => %{"theme" => "bla"},
-                 "masto_fe" => %{"theme" => "bla"}
+                 "soapbox_fe" => %{"themeMode" => "bla"}
                }
 
       user = Repo.get(User, user_data["id"])
@@ -60,8 +60,8 @@ defmodule Pleroma.Web.MastodonAPI.UpdateCredentialsTest do
           |> assign(:user, user)
           |> patch("/api/v1/accounts/update_credentials", %{
             "pleroma_settings_store" => %{
-              masto_fe: %{
-                theme: "blub"
+              soapbox_fe: %{
+                themeMode: "blub"
               }
             }
           })
@@ -71,7 +71,7 @@ defmodule Pleroma.Web.MastodonAPI.UpdateCredentialsTest do
         assert user_data["pleroma"]["settings_store"] ==
                  %{
                    "pleroma_fe" => %{"theme" => "bla"},
-                   "masto_fe" => %{"theme" => "blub"}
+                   "soapbox_fe" => %{"themeMode" => "blub"}
                  }
 
         assert_called(Pleroma.Web.Federator.publish(:_))
@@ -88,9 +88,7 @@ defmodule Pleroma.Web.MastodonAPI.UpdateCredentialsTest do
       assert user_data = json_response_and_validate_schema(conn, 200)
 
       assert user_data["note"] ==
-               ~s(I drink <a class="hashtag" data-tag="cofe" href="http://localhost:4001/tag/cofe">#cofe</a> with <span class="h-card"><a class="u-url mention" data-user="#{
-                 user2.id
-               }" href="#{user2.ap_id}" rel="ugc">@<span>#{user2.nickname}</span></a></span><br/><br/>suya..)
+               ~s(I drink <a class="hashtag" data-tag="cofe" href="http://localhost:4001/tag/cofe">#cofe</a> with <span class="h-card"><a class="u-url mention" data-user="#{user2.id}" href="#{user2.ap_id}" rel="ugc">@<span>#{user2.nickname}</span></a></span><br/><br/>suya..)
 
       assert user_data["source"]["note"] == raw_bio