aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorlain <lain@soykaf.club>2020-06-22 13:23:21 +0200
committerlain <lain@soykaf.club>2020-06-22 13:23:21 +0200
commit1e7ca2443011f65aa766c3ddd5cd1203e79db50b (patch)
tree792a925c4c56d386cc9d7c9b4c53bc253ac10780
parent9438f83f83305f101b9fed65f68a5b9fd622bcbb (diff)
downloadpleroma-1e7ca2443011f65aa766c3ddd5cd1203e79db50b.tar.gz
Update Handling Test: Fix for re-used update ids.
-rw-r--r--test/web/activity_pub/transmogrifier/user_update_handling_test.exs9
1 files changed, 7 insertions, 2 deletions
diff --git a/test/web/activity_pub/transmogrifier/user_update_handling_test.exs b/test/web/activity_pub/transmogrifier/user_update_handling_test.exs
index 8e5d3b883..64636656c 100644
--- a/test/web/activity_pub/transmogrifier/user_update_handling_test.exs
+++ b/test/web/activity_pub/transmogrifier/user_update_handling_test.exs
@@ -106,11 +106,13 @@ defmodule Pleroma.Web.ActivityPub.Transmogrifier.UserUpdateHandlingTest do
Pleroma.Config.put([:instance, :max_remote_account_fields], 2)
update_data =
- put_in(update_data, ["object", "attachment"], [
+ update_data
+ |> put_in(["object", "attachment"], [
%{"name" => "foo", "type" => "PropertyValue", "value" => "bar"},
%{"name" => "foo11", "type" => "PropertyValue", "value" => "bar11"},
%{"name" => "foo22", "type" => "PropertyValue", "value" => "bar22"}
])
+ |> Map.put("id", update_data["id"] <> ".")
{:ok, _} = Transmogrifier.handle_incoming(update_data)
@@ -121,7 +123,10 @@ defmodule Pleroma.Web.ActivityPub.Transmogrifier.UserUpdateHandlingTest do
%{"name" => "foo1", "value" => "updated"}
]
- update_data = put_in(update_data, ["object", "attachment"], [])
+ update_data =
+ update_data
+ |> put_in(["object", "attachment"], [])
+ |> Map.put("id", update_data["id"] <> ".")
{:ok, _} = Transmogrifier.handle_incoming(update_data)