using `stub` instead `expect`
authorAlexander Strizhakov <alex.strizhakov@gmail.com>
Sat, 7 Mar 2020 07:12:34 +0000 (10:12 +0300)
committerAlexander Strizhakov <alex.strizhakov@gmail.com>
Sat, 7 Mar 2020 07:12:34 +0000 (10:12 +0300)
test/http/adapter_helper/gun_test.exs

index b1b34858a9fb47b72d5d3fe6f6a17a0808e04eb3..c65b897868d6b5714d7c5c2c6ca1ac933edc37ca 100644 (file)
@@ -23,7 +23,7 @@ defmodule Pleroma.HTTP.AdapterHelper.GunTest do
 
   defp gun_mock do
     Pleroma.GunMock
-    |> expect(:open, fn _, _, _ -> Task.start_link(fn -> Process.sleep(1000) end) end)
+    |> stub(:open, fn _, _, _ -> Task.start_link(fn -> Process.sleep(1000) end) end)
     |> expect(:await_up, fn _, _ -> {:ok, :http} end)
     |> expect(:set_owner, fn _, _ -> :ok end)
   end