X-Git-Url: https://git.squeep.com/?a=blobdiff_plain;ds=sidebyside;f=test%2Fpleroma%2Fweb%2Fo_status%2Fo_status_controller_test.exs;h=41aef98b1cb2bba140f7992eee15082870a202f0;hb=cb9b0d3720cdfe5e9987d70d0822032fef7a3d8a;hp=2038f4ddd12bd654062a9484695892f59ba381b9;hpb=6e68058b634dced932a1283f8470598b5cabdfeb;p=akkoma
diff --git a/test/pleroma/web/o_status/o_status_controller_test.exs b/test/pleroma/web/o_status/o_status_controller_test.exs
index 2038f4ddd..41aef98b1 100644
--- a/test/pleroma/web/o_status/o_status_controller_test.exs
+++ b/test/pleroma/web/o_status/o_status_controller_test.exs
@@ -182,7 +182,7 @@ defmodule Pleroma.Web.OStatus.OStatusControllerTest do
|> response(200)
assert resp =~
- ""
+ ""
user = insert(:user)
@@ -343,4 +343,54 @@ defmodule Pleroma.Web.OStatus.OStatusControllerTest do
|> response(200)
end
end
+
+ describe "notice compatibility routes" do
+ test "Soapbox FE", %{conn: conn} do
+ user = insert(:user)
+ note_activity = insert(:note_activity, user: user)
+
+ resp =
+ conn
+ |> put_req_header("accept", "text/html")
+ |> get("/@#{user.nickname}/posts/#{note_activity.id}")
+ |> response(200)
+
+ expected =
+ ""
+
+ assert resp =~ expected
+ end
+
+ test "Mastodon", %{conn: conn} do
+ user = insert(:user)
+ note_activity = insert(:note_activity, user: user)
+
+ resp =
+ conn
+ |> put_req_header("accept", "text/html")
+ |> get("/@#{user.nickname}/#{note_activity.id}")
+ |> response(200)
+
+ expected =
+ ""
+
+ assert resp =~ expected
+ end
+
+ test "Twitter", %{conn: conn} do
+ user = insert(:user)
+ note_activity = insert(:note_activity, user: user)
+
+ resp =
+ conn
+ |> put_req_header("accept", "text/html")
+ |> get("/#{user.nickname}/status/#{note_activity.id}")
+ |> response(200)
+
+ expected =
+ ""
+
+ assert resp =~ expected
+ end
+ end
end