diff options
author | Ivan Tashkinov <ivantashkinov@gmail.com> | 2020-03-11 09:15:55 +0300 |
---|---|---|
committer | Ivan Tashkinov <ivantashkinov@gmail.com> | 2020-03-11 09:15:55 +0300 |
commit | 972889550da0f623693eeb3b2d1ca3025501e5eb (patch) | |
tree | 175d795fcd44230b20913d162d96516bbab81989 /test | |
parent | 5fc92deef37dcc4db476520d89dd79e616356e63 (diff) | |
parent | 953aece84866a89bd3de8f6d3f5d30e2f9cfb4f3 (diff) | |
download | pleroma-972889550da0f623693eeb3b2d1ca3025501e5eb.tar.gz |
Merge remote-tracking branch 'remotes/origin/develop' into 1560-non-federating-instances-routes-restrictions
Diffstat (limited to 'test')
-rw-r--r-- | test/web/common_api/common_api_test.exs | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/test/web/common_api/common_api_test.exs b/test/web/common_api/common_api_test.exs index 299d968db..b80523160 100644 --- a/test/web/common_api/common_api_test.exs +++ b/test/web/common_api/common_api_test.exs @@ -202,13 +202,15 @@ defmodule Pleroma.Web.CommonAPITest do CommonAPI.post(user, %{"status" => ""}) end - test "it returns error when character limit is exceeded" do + test "it validates character limits are correctly enforced" do Pleroma.Config.put([:instance, :limit], 5) user = insert(:user) assert {:error, "The status is over the character limit"} = CommonAPI.post(user, %{"status" => "foobar"}) + + assert {:ok, activity} = CommonAPI.post(user, %{"status" => "12345"}) end test "it can handle activities that expire" do |