fix tests
authorFloatingGhost <hannah@coffee-and-dreams.uk>
Thu, 11 Aug 2022 18:21:43 +0000 (19:21 +0100)
committerFloatingGhost <hannah@coffee-and-dreams.uk>
Thu, 11 Aug 2022 18:21:43 +0000 (19:21 +0100)
test/pleroma/web/federator_test.exs
test/pleroma/workers/receiver_worker_test.exs

index 3ae266ecdf6b716e613c05cb287b26b9673c33bb..c329721819e04ae7ec1d21ed0ee77df63a6e3cb4 100644 (file)
@@ -153,7 +153,7 @@ defmodule Pleroma.Web.FederatorTest do
       }
 
       assert {:ok, job} = Federator.incoming_ap_doc(params)
-      assert {:cancel, :origin_containment_failed} = ObanHelpers.perform(job)
+      assert {:discard, :origin_containment_failed} = ObanHelpers.perform(job)
     end
 
     test "it does not crash if MRF rejects the post" do
@@ -169,7 +169,7 @@ defmodule Pleroma.Web.FederatorTest do
         |> Jason.decode!()
 
       assert {:ok, job} = Federator.incoming_ap_doc(params)
-      assert {:cancel, _} = ObanHelpers.perform(job)
+      assert {:discard, _} = ObanHelpers.perform(job)
     end
   end
 end
index 283beee4d552293f22a01a2bf184e0ad065a43f3..e726e6308bd9687cdd7a88a01abe275bf037eec1 100644 (file)
@@ -16,7 +16,7 @@ defmodule Pleroma.Workers.ReceiverWorkerTest do
 
     with_mock Pleroma.Web.ActivityPub.Transmogrifier,
       handle_incoming: fn _ -> {:reject, "MRF"} end do
-      assert {:cancel, "MRF"} =
+      assert {:discard, "MRF"} =
                ReceiverWorker.perform(%Oban.Job{
                  args: %{"op" => "incoming_ap_doc", "params" => params}
                })