diff options
author | lain <lain@soykaf.club> | 2018-05-04 21:15:39 +0200 |
---|---|---|
committer | lain <lain@soykaf.club> | 2018-05-04 21:15:39 +0200 |
commit | 90c4bed0af40911e0f8a28743814e4c07e91e9ae (patch) | |
tree | e6d016d7b5d27ad986af578be4fa63f80704ad43 /test | |
parent | fcd3eca167508c1dde290f431353ace9d513de86 (diff) | |
download | pleroma-90c4bed0af40911e0f8a28743814e4c07e91e9ae.tar.gz pleroma-90c4bed0af40911e0f8a28743814e4c07e91e9ae.zip |
Don't expire idempotency cache for five minutes.
Diffstat (limited to 'test')
-rw-r--r-- | test/web/mastodon_api/mastodon_api_controller_test.exs | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/test/web/mastodon_api/mastodon_api_controller_test.exs b/test/web/mastodon_api/mastodon_api_controller_test.exs index 432dca28a..69a0299ac 100644 --- a/test/web/mastodon_api/mastodon_api_controller_test.exs +++ b/test/web/mastodon_api/mastodon_api_controller_test.exs @@ -75,6 +75,10 @@ defmodule Pleroma.Web.MastodonAPI.MastodonAPIControllerTest do "sensitive" => "false" }) + {:ok, ttl} = Cachex.ttl(:user_cache, "idem:#{idempotency_key}") + # 5 Minutes + assert ttl > :timer.seconds(5 * 60 - 1) + assert %{"content" => "cofe", "id" => id, "spoiler_text" => "2hu", "sensitive" => false} = json_response(conn_one, 200) |