diff options
author | tusooa <tusooa@kazv.moe> | 2022-11-05 23:36:10 -0400 |
---|---|---|
committer | tusooa <tusooa@kazv.moe> | 2023-02-20 12:28:41 -0500 |
commit | 0e89a9ad15bd86731b3babfced990d1d8ec7db4c (patch) | |
tree | beca2aa5125999510768fc6d5343a0b82c870dac | |
parent | c3a07035646b255bc5f33743d13defbaa69d9991 (diff) | |
download | pleroma-0e89a9ad15bd86731b3babfced990d1d8ec7db4c.tar.gz pleroma-0e89a9ad15bd86731b3babfced990d1d8ec7db4c.zip |
Test that zwnj is treated as word char in hashtags
-rw-r--r-- | test/pleroma/web/common_api_test.exs | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/test/pleroma/web/common_api_test.exs b/test/pleroma/web/common_api_test.exs index 44355c26d..2876d4093 100644 --- a/test/pleroma/web/common_api_test.exs +++ b/test/pleroma/web/common_api_test.exs @@ -518,6 +518,15 @@ defmodule Pleroma.Web.CommonAPITest do assert Object.tags(object) == ["2hu"] end + test "zwnj is treated as word character" do + user = insert(:user) + {:ok, activity} = CommonAPI.post(user, %{status: "#ساٴينس"}) + + object = Object.normalize(activity, fetch: false) + + assert Object.tags(object) == ["ساٴينس"] + end + test "it adds emoji in the object" do user = insert(:user) {:ok, activity} = CommonAPI.post(user, %{status: ":firefox:"}) |